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
| mode gjenkjennes ikke som en intern eller ekstern kommando, | |
| kjørbart program eller satsvis fil. | |
| Welcome to gmvault (version 1.8.1-beta). | |
| Run gmvault --help to display the help. | |
| Run gmvault {command} --help to display help for specific commands. | |
| gmvault-shell>gmvault --help | |
| Anders gjenkjennes ikke som en intern eller ekstern kommando, | |
| kjørbart program eller satsvis fil. |
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
| Welcome to gmvault (version 1.8.1-beta). | |
| Run gmvault --help to display the help. | |
| Run gmvault {command} --help to display help for specific commands. | |
| gmvault-shell>gmvault --help | |
| Anders gjenkjennes ikke som en intern eller ekstern kommando, | |
| kjørbart program eller satsvis fil. | |
| usage: gmvault [-h] [-v] {sync,restore,check,export} ... |
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
| https://github.com/trinidad/trinidad/wiki/init.d-scripts | |
| #!/bin/sh | |
| set -e | |
| # Must be a valid filename | |
| NAME=trr | |
| #/var/run/app must be writable by your user | |
| PIDFILE=/var/run/app/trr.pid |
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 | |
| import sys | |
| from twitter import * | |
| if len(sys.argv) > 1: | |
| def read_data_file(filename): | |
| f = open(filename) | |
| return f.readline().strip(), f.readline().strip(), f.readline().strip(), f.readline().strip() | |
| handle=sys.argv[1] | |
| exclude_replies=0 |
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
| hildenae@offle:~/tmp/twitter$ cat kopweb.py | |
| from twitter import * | |
| #oauth_dance("My App Name", CONSUMER_KEY, CONSUMER_SECRET, MY_TWITTER_CREDS) | |
| oauth_token="###############" | |
| oauth_secret="##############" | |
| CONSUMER_KEY="#############" | |
| CONSUMER_SECRET="###########" | |
| # = read_token_file(MY_TWITTER_CREDS) | |
| t = Twitter(auth=OAuth(oauth_token, oauth_secret, CONSUMER_KEY, CONSUMER_SECRET)) |
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/perl | |
| use warnings; | |
| use strict; | |
| use LWP::Simple; | |
| use XML::XPath; | |
| use XML::XPath::XMLParser; | |
| my $file = 'today.xml'; | |
| unlink($file); |
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
| diff --git a/perllib/FixMyStreet/Geocode/Google.pm b/perllib/FixMyStreet/Geocode/Google.pm | |
| index 83b36db..b3beccf 100644 | |
| --- a/perllib/FixMyStreet/Geocode/Google.pm | |
| +++ b/perllib/FixMyStreet/Geocode/Google.pm | |
| @@ -75,6 +75,10 @@ sub string { | |
| my $address = $_->{address}; | |
| next unless $c->cobrand->geocoded_string_check( $address ); | |
| ( $longitude, $latitude ) = @{ $_->{Point}->{coordinates} }; | |
| + mySociety::Locale::in_gb_locale { | |
| + $longitude = "$longitude"; |
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/perl | |
| use strict; | |
| use warnings; | |
| if ($#ARGV < 0 ) { | |
| print "usage: $0 <path> [path...]\n"; | |
| exit; | |
| } | |
| my $file = $ARGV[0]; | |
| # Check that the path exsists, is a file, and is readable |
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
| munmap(0xf77a8000, 4096) = 0 | |
| stat64("/var/log/apache2/access.log", {st_mode=S_IFREG|0640, st_size=2162990674, ...}) = 0 | |
| open("/var/log/apache2/access.log", O_RDONLY|O_LARGEFILE) = 3 | |
| fstat64(3, {st_mode=S_IFREG|0640, st_size=2162990674, ...}) = 0 | |
| _llseek(3, 0, [2162990674], SEEK_END) = 0 | |
| _llseek(3, 0, [0], SEEK_SET) = 0 | |
| --- SIGSEGV (Segmentation fault) @ 0 (0) --- | |
| +++ killed by SIGSEGV +++ |
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
| manager:~/scripts# cat foreach_host.sh | |
| for hostname in $(cat /etc/hosts | awk '{print $NF}'); do echo "Working on hostname: $hostname"; $1; done; | |
| manager:~/scripts# ./foreach_host.sh 'nc $hostname 4949' | |
| Working on hostname: manager | |
| $hostname: forward host lookup failed: Unknown host |