sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh
| # This is the complete source code to Flappy Dragon: | |
| # https://dragonruby.itch.io/flappydragon | |
| # | |
| # You can tinker with this by getting a copy of DragonRuby Game Toolkit: | |
| # https://dragonruby.org/ | |
| # | |
| # Amir Rajan wrote this game, catch him at https://twitter.com/amirrajan ! | |
| class FlappyDragon | |
| attr_accessor :grid, :inputs, :game, :outputs |
| String.prototype.padLeft = function (n, str) { | |
| if (n < String(this).length) { | |
| return this.toString(); | |
| } | |
| else { | |
| return Array(n - String(this).length + 1).join(str || '0') + this; | |
| } | |
| } | |
| function crc16(s) { |
| # Automation for Dhuhr, Asr, Maghrib, and Isha Adhan | |
| - action: | |
| - alias: '' | |
| data: | |
| entity_id: media_player.family_room_speaker # replace with your Google Home's id | |
| media_content_id: https://www.youtube.com/watch?v=ADLO-Hm_nCQ # replace with your choice of Adhan | |
| media_content_type: audio/youtube | |
| service: media_extractor.play_media | |
| - data: | |
| entity_id: media_player.family_room_speaker # replace with your Google Home's id |
| RN < 0.50 - watchman watch-del-all && rm -rf $TMPDIR/react-* && rm -rf node_modules/ && npm cache clean && npm install && npm start -- --reset-cache | |
| RN >= 0.50 - watchman watch-del-all && rm -rf $TMPDIR/react-native-packager-cache-* && rm -rf $TMPDIR/metro-bundler-cache-* && rm -rf node_modules/ && npm cache clean && npm install && npm start -- --reset-cache | |
| RN >= 0.63 - watchman watch-del-all && rm -rf node_modules && npm install && rm -rf /tmp/metro-* && npm run start --reset-cache | |
| npm >= 5 - watchman watch-del-all && rm -rf $TMPDIR/react-* && rm -rf node_modules/ && npm cache verify && npm install && npm start -- --reset-cache | |
| Windows - del %appdata%\Temp\react-native-* & cd android & gradlew clean & cd .. & del node_modules/ & npm cache clean --force & npm install & npm start -- --reset-cache |
git config --global alias.checkoutr checkout
$EDITOR /usr/local/share/zsh/site-functions/git-completion.bash...and then modify the file as follows...
-__gitcomp_nl "$(__git_refs '' $track)"
+if [ "$command" = "checkoutr" ]; then
+ __gitcomp_nl "$(__git_refs '' $track)"
+else| class Integer | |
| N_BYTES = [42].pack('i').size | |
| N_BITS = N_BYTES * 16 | |
| MAX = 2 ** (N_BITS - 2) - 1 | |
| MIN = -MAX - 1 | |
| end | |
| p Integer::MAX #=> 4611686018427387903 | |
| p Integer::MAX.class #=> Fixnum | |
| p (Integer::MAX + 1).class #=> Bignum |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000