Workflow:
- Download the binary of a desired python version
- Create a virtual environment that uses the desired python binary
# List all available versions| # Update base conda if required | |
| conda update -n root conda | |
| # Update all conda packages | |
| conda update --all |
| import argparse | |
| if __name__ == "__main__": | |
| parser = argparse.ArgumentParser( | |
| description='Describe the utility.' | |
| ) | |
| # This is a required argument | |
| parser.add_argument( | |
| 'filepath', | |
| type=str, |
| #================= | |
| # Add Custom PPAs | |
| #================= | |
| # For latest stable git | |
| sudo add-apt-repository ppa:git-core/ppa | |
| sudo apt install git -y | |
| # GUI to easily change GRUB boot order (set Windows first for its updates) | |
| sudo add-apt-repository ppa:danielrichter2007/grub-customizer | |
| sudo apt install grub-customizer -y |
| ## For Elementary OS 5.0 | |
| # Enable adding custom PPA's | |
| apt install software-properties-common | |
| # PulseAudio volume control | |
| apt install -y pavucontrol | |
| # Elementary Tweaks | |
| sudo add-apt-repository ppa:philip.scott/elementary-tweaks | |
| sudo apt install elementary-tweaks |
| # Find text in files in current directory | |
| # -i - ignore text case | |
| # -r - recursively search files in subdirectories. | |
| # -n is line number, and | |
| # -l - show file names instead of file contents portions. | |
| grep -irn "search string" . | |
| # Update system time from google (used to be able to do `sudo ntpdate time.nist.gov`, but ntpdate is considered deprecated as of 16.04 | |
| # Caveat: Might be 8-50 ms behind | |
| sudo date -s "$(wget -qSO- --max-redirect=0 google.com 2>&1 | grep Date: | cut -d" " -f5-8)Z" |
| # Source: https://github.com/tensorflow/tensorflow/issues/559 | |
| # Check the current numpy version (and any error messages that come up) | |
| python -c "import numpy;print numpy.__version__;print numpy.__file__"; | |
| # Do this a few times until all versions of numpy are removed | |
| pip uninstall numpy | |
| # Reinstall numpy | |
| pip install -U numpy |
| # Source: https://github.com/RemoteDebug/remotedebug-ios-webkit-adapter | |
| #================================ | |
| #=== Install libimobiledevice === | |
| #================================ | |
| # Source: https://github.com/libimobiledevice/libimobiledevice | |
| sudo apt install autoconf autotools-dev -y | |
| # Clone the required repos | |
| git clone https://github.com/libimobiledevice/libplist |
| // Override console log to show messages on frontend. Useful for debugging on mobile (where console is unavailable). | |
| // | |
| // Example HTML: | |
| // | |
| // <div id="log"></div> | |
| // | |
| // Source: https://stackoverflow.com/a/20256785 | |
| (function () { | |
| var old = console.log; |
| # Source: https://askubuntu.com/a/511281 | |
| xinput --list --short | grep -i trackpoint | |
| # In this case, device id=16. This lists all available properties and current values | |
| xinput list-props 16 | |
| # Change from 1.0 to 0.35 for higher sensitivity | |
| xinput --set-prop 16 "Device Accel Constant Deceleration" 0.35 | |
| ## Add the above command to Startup Applications |