layout | title | date | comments | categories | published | ||
---|---|---|---|---|---|---|---|
post |
How do I even Minecraft? |
2013-11-11 10:32 |
true |
|
false |
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 ruby | |
require 'cfpropertylist' | |
plist = CFPropertyList::List.new(file: ARGV[0]) | |
service_definition = CFPropertyList.native_types(plist.value) | |
puts service_definition['ProgramArguments'].map { |x| '"' + x + '"' }.join(' ') |
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 csv | |
from datetime import datetime | |
import sys | |
mt940_reader = csv.DictReader(sys.stdin, delimiter=';') | |
ynab_writer = csv.DictWriter(sys.stdout, fieldnames=('Date', 'Payee', 'Category', 'Memo', 'Outflow', 'Inflow')) | |
ynab_writer.writeheader() | |
for mt940_row in mt940_reader: | |
valuation_date = datetime.strptime(mt940_row['Valutadatum'], '%d.%m.%y') |
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
# Enable the update/upgrade script (0=disable) | |
APT::Periodic::Enable "1"; | |
# Do "apt-get update" automatically every n-days (0=disable) | |
APT::Periodic::Update-Package-Lists "1"; | |
# Do "apt-get upgrade --download-only" every n-days (0=disable) | |
APT::Periodic::Download-Upgradeable-Packages "1"; | |
# Do "apt-get autoclean" every n-days (0=disable) |
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
- hosts: all | |
tasks: | |
- name: create monitoring user | |
user: name=monitoring system=yes | |
- name: generate SSH key for Icinga | |
user: | |
name=icinga | |
generate_ssh_key=yes | |
register: icinga_ssh_key | |
delegate_to: monitoring.mxey.net |
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
--- | |
- hosts: website | |
vars: | |
version: 0.4.1 | |
root: /opt/ghost | |
temp_zip_file: /opt/ghost-new.zip | |
tasks: | |
- name: fetch | |
get_url: "dest={{temp_zip_file}} url=https://ghost.org/zip/ghost-{{version}}.zip" | |
- name: remove old core |
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
#!/bin/sh | |
. /etc/rc.subr | |
name=ghost | |
rcvar=ghost_enable | |
command="/opt/ghost/index.js" | |
command_interpreter="/usr/local/bin/node" | |
ghost_user="ghost" |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>net.mxey.homebrew.upgrade</string> | |
<key>ProgramArguments</key> | |
<array> | |
<string>/Users/mxey/bin/upgrade-homebrew-on-ac</string> | |
</array> |
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
mxey@mxeybook ~ % pmset -g assertions | |
23.10.13 11:33:45 MESZ | |
Assertion status system-wide: | |
BackgroundTask 0 | |
PreventDiskIdle 0 | |
ApplePushServiceTask 0 | |
UserIsActive 1 | |
PreventUserIdleDisplaySleep 0 | |
InteractivePushServiceTask 0 | |
PreventSystemSleep 0 |
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
#!/bin/sh -ex | |
cd /home/shaperia | |
rm -f happyman_backup.sqlite.new happyman_backup.sqlite.new.xz | |
echo .backup happyman_backup.sqlite.new | sqlite3 ./happyman/cobe.sqlite | |
xz happyman_backup.sqlite.new | |
mv happyman_backup.sqlite.new.xz happyman_backup.sqlite.xz |