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
| import sys | |
| sys.path.append('/usr/local/munki/munkilib') | |
| import fetch | |
| fetch.get_url('http://www.irs.gov/pub/irs-prior/f1040ez--2014.pdf', '/Users/ryan/Desktop/1040ez.pdf') | |
| fetch.get_url('https://www.gnu.org/software/wget/index.html', '/Users/ryan/Desktop/index.html') |
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
| from munkilib import gurl | |
| def run_connection(options): | |
| connection = gurl.Gurl.alloc().initWithOptions_(options) | |
| percent_complete = -1 | |
| bytes_received = 0 | |
| connection.start() | |
| try: | |
| while not connection.isDone(): | |
| if connection.destination_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
| from ctypes import CDLL | |
| loginPF = CDLL('/System/Library/PrivateFrameworks/login.framework/Versions/Current/login') | |
| result = loginPF.SACLockScreenImmediate() |
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
| #!/usr/bin/python | |
| # encoding: utf-8 | |
| # | |
| # Copyright 2009-2016 Greg Neagle. | |
| # | |
| # Licensed under the Apache License, Version 2.0 (the 'License'); | |
| # you may not use this file except in compliance with the License. | |
| # You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 |
OlderNewer