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
| VIRTUAL_ENV=/opt/myenv | |
| PATH=$VIRTUAL_ENV/bin:$PATH |
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
| # pylint: disable=R0904 |
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
| #!/bin/bash | |
| # Colours | |
| ESC_SEQ="\x1b[" | |
| COL_RESET=$ESC_SEQ"39;49;00m" | |
| COL_RED=$ESC_SEQ"31;01m" | |
| COL_GREEN=$ESC_SEQ"32;01m" | |
| COL_YELLOW=$ESC_SEQ"33;01m" | |
| COL_BLUE=$ESC_SEQ"34;01m" | |
| COL_MAGENTA=$ESC_SEQ"35;01m" |
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
| #!/bin/bash | |
| # In this example checking for directories containing Python files | |
| find -iname '*.py' -printf '%h/\n' |
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
| #!/bin/bash | |
| # Use \( and \) to create a match group in the find part, use \1 in the replace part to reference the match group. | |
| echo "./ThingToMatch/other/stuff/" | sed -n 's/\.\/\([a-zA-Z0-9]*\)\/.*/\1/p' | |
| # This will output: ThingToMatch | |
| # Works with multiline input, applying the replacement to each line. |
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
| python -m SimpleHTTPServer 8000 |
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
| curl -s server.com/file | sh |
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
| $(git rev-parse --show-toplevel) |
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
| title restart-all | |
| call taskkill /F /t /IM cmd.exe /fi "Windowtitle ne restart-all" | |
| call taskkill /F /IM cmd.exe /fi "Windowtitle ne restart-all" | |
| call taskkill /F /IM iexplore.exe | |
| call taskkill /F /IM IEDriverServer.exe | |
| start cmd.exe /k hub.bat | |
| start cmd.exe /k node.bat | |
| start cmd.exe /k phantomjs.bat |
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
| sudo find . -type f -name "*.pyc" -delete |
OlderNewer