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
#!pydsl | |
# vim:set syntax=python : | |
# sublime: x_syntax Packages/Python/Python.tmLanguage |
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
Show hidden characters
{ | |
"bold_folder_labels": true, | |
"caret_style": "phase", | |
"color_scheme": "Packages/Dayle Rees Color Schemes/BlueDawn.tmTheme", | |
"detect_indentation": false, | |
"dictionary": "Packages/Language - English/en_GB.dic", | |
"draw_white_space": "all", | |
"ensure_newline_at_eof_on_save": true, | |
"fade_fold_buttons": false, | |
"font_face": "Source Code Pro", |
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
from salt.client import LocalClient | |
client = LocalClient() | |
o = client.cmd(t, 'cmd.run_all', kwarg={ | |
'cmd': 'curl *options and url redacted*', | |
'cwd': dirname | |
}) | |
print "Ret: %(retcode)d\n\nstdout:\n%(stdout)s\n\nstderr:\n%(stderr)s\n" % o[t] | |
print o[t], "\n" | |
if o[t]['retcode'] != 0: | |
client.cmd(t, 'file.remove', arg=(dirname,), timeout=5) |
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
ak = state("%s_keywords"%(self.state_name)) | |
ak.file.managed( | |
"/etc/portage/package.accept_keywords/%s" % ( self.state_name ), | |
source="salt://roles/%s/%s" % ( self.state_name, | |
(type(self.keywords_file) == str) and keywords_file or "accept_keywords" | |
), | |
user="root", group="root", mode="0644", template="jinja") |
I hereby claim:
- I am kaithar on github.
- I am kaithar (https://keybase.io/kaithar) on keybase.
- I have a public key whose fingerprint is 06C6 EF94 63AD DE67 2521 FBBA 14C6 F66E C366 69C3
To claim this, I am signing this object:
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
import cfscrape | |
import http.cookiejar | |
scraper = cfscrape.create_scraper() | |
try: | |
import config | |
scraper.headers["User-Agent"] = config.UA | |
except: | |
# Oh well |