This file contains 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
#!/usr/bin/env bash | |
dir=$(dirname $0) | |
gconfdir=/apps/gnome-terminal/profiles | |
echo # This makes the prompts easier to follow (as do other random echos below) | |
######################## | |
### Select a profile ### | |
######################## |
This file contains 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
#!/usr/bin/ruby | |
# ruby script to create a directory structure from indented data. | |
# Three ways to use it: | |
# - Pipe indented (tabs or 2 spaces) text to the script | |
# - e.g. `cat "mytemplate" | planter.rb | |
# - Create template.tpl files in ~/.planter and call them by their base name | |
# - e.g. Create a text file in ~/.planter/site.tpl | |
# - `planter.rb site` | |
# - Call planter.rb without input and it will open your $EDITOR to create the tree on the fly | |
# You can put %%X%% variables into templates, where X is a number that corresponds to the index |
This file contains 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
def replace_item(inventory, item): | |
for item in range( len(list) ): | |
if item != new_item: | |
list[item] = new_item | |
return list | |
inventory = range(26) | |
new_item = "" | |
print replace_item(inventory, new_item) |
This file contains 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
#this function replaces an existing index with a new one. | |
def replace_item(inventory,new_item): | |
for i,item in enumerate(inventory): | |
if item != new_item: | |
inventory[i] = new_item | |
return inventory | |
my_inv = [0]*26 | |
sword = "sword" | |
bow = "bow" |
This file contains 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
Example, to kill the Thunderbird app: | |
# fuck thunderbird | |
(ノಠ益ಠ)ノ彡pɹıqɹǝpunɥʇ |
This file contains 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
#!/usr/bin/env bash | |
# Additional 32-bit libraries needed to run the game Salvation Prophecy on 64-bit Debian systems. | |
# This was crafted on Ubuntu 14.04. Use ldd on the SalvationProphecy binary | |
# to determine if there any additional libraries required on your distro. | |
sudo apt-get install libxaw7:i386 libjasper1:i386 liblcms1:i386 |
This file contains 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
#! /usr/bin/env python2 | |
'''Use your webcam to open a QR code embedded URL with your default web browser.''' | |
from qrtools import QR | |
import webbrowser | |
myCode = QR() | |
myCode.decode_webcam(lambda data: webbrowser.open(data)) |
This file contains 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
00:00.146 SYSTEM locking /Users/jesse/.opam/lock | |
00:00.147 FILENAME cleandir /Users/jesse/.opam/log | |
00:00.147 SYSTEM rmdir /Users/jesse/.opam/log | |
00:00.151 SYSTEM mkdir /Users/jesse/.opam/log | |
00:00.151 STATE LOAD-STATE(global-lock) | |
00:00.151 FILE(config) Read ~/.opam/config in 0.000s | |
00:00.160 STATE Loaded /Users/jesse/.opam/state.cache in 0.009s | |
00:00.161 FILE(aliases) Read ~/.opam/aliases in 0.000s | |
00:00.171 FILE(repo-config) Read ~/.opam/repo/android/config in 0.000s | |
00:00.171 FILE(repo-config) Read ~/.opam/repo/default/config in 0.000s |
This file contains 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
/* | |
----------------------------------------------------------------------------- | |
This source file is part of OGRE | |
(Object-oriented Graphics Rendering Engine) | |
For the latest info, see http://www.ogre3d.org/ | |
Copyright (c) 2000-2012 Torus Knot Software Ltd | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal |
This file contains 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
#! python3 | |
import shlex | |
import sys | |
import re | |
import io | |
header = open('openvr.h', newline='\n').read() | |
annoyingMacroPattern = re.compile(r'#define\s+(\w+).*VR_CLANG_ATTR.*') |
OlderNewer