This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from glob import glob | |
| import io | |
| import os | |
| import time | |
| import uuid | |
| from zipfile import ZipFile | |
| # third party libraries | |
| import jwt # PyJWT | |
| import requests | |
| # get API keys from https://addons.mozilla.org/developers/addon/api/key/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import pythoncom | |
| import win32com | |
| import win32com.client as client | |
| from shutil import copyfile, rmtree | |
| import threading | |
| from contextlib import suppress | |
| wdFormatPDF = 17 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javers Javers = JaversBuilder.javers() | |
| // ... | |
| // ignore Entity/Key Object | |
| .registerEntity(EntityDefinitionBuilder.entityDefiniition(Square.class) | |
| .withIdPropertyName("key") | |
| .withIgnoredProperties("lastUpdate", "comments") | |
| .build()) | |
| // ignore Value Object | |
| .registerValueObject(new ValueObjectDefinitioin(Vertex.class, Arrays.asList("lastUpdate", "comments")) | |
| // you can use both multiple times |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... | |
| Diff diff = differ.compare(left, right); | |
| List<Change> changes = new ArrayList<>(diff.getChanges()); | |
| List<Change> ignoredChanges = diff.getPropertyChanges("comments"); | |
| for (Change ignoreChange : ignoredChanges) { | |
| changes.remove(ignoreChange); | |
| } | |
| // ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.elijahlopez.examples; | |
| import java.awt.Color; | |
| import java.util.Date; | |
| // e.g. Class Vertex - modifiable source code | |
| public class Vertex { | |
| @DiffIgnore | |
| Date lastUpdated; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| AudioPlayer v2.3.7 | |
| Author: Elijah Lopez | |
| Make sure VLC .dll files are located in "vlc_lib/" | |
| """ | |
| import math | |
| import os | |
| import platform | |
| import sys | |
| import time |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import subprocess | |
| import shutil | |
| import os | |
| import zipfile | |
| import threading | |
| print('Cleaning up build directory') | |
| shutil.rmtree('Builds', ignore_errors=True) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using UnityEditor; | |
| using UnityEditor.Build.Reporting; | |
| using UnityEngine; | |
| public class BuildScript | |
| { | |
| [MenuItem("File/Build All")] | |
| static void BuildAll() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import platform | |
| from subprocess import Popen, PIPE, DEVNULL | |
| def get_running_processes(look_for='', pid=None, add_exe=True): | |
| # TODO: Linux implementation | |
| cmd = f'tasklist /NH' | |
| if look_for: | |
| if not look_for.endswith('.exe') and add_exe: | |
| look_for += '.exe' | |
| cmd += f' /FI "IMAGENAME eq {look_for}"' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import threading | |
| import time | |
| # there's also a multiprocessing module which I haven't used because its easier to communicate between threads | |
| # than it is to communicate between processes | |
| # for each section uncomment the code and run it | |