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
diff --git a/nixops/backends/__init__.py b/nixops/backends/__init__.py | |
index 86ed0f4..c52e9d3 100644 | |
--- a/nixops/backends/__init__.py | |
+++ b/nixops/backends/__init__.py | |
@@ -93,6 +93,17 @@ class MachineState(nixops.resources.ResourceState): | |
except nixops.ssh_util.SSHCommandFailed: | |
return None | |
+ def get_os_arch(self): | |
+ """Get the machine's OS archicture.""" |
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
{ config, pkgs, lib, ... }: | |
{ | |
# Other host options | |
## Containers | |
# Containers are bridged with the physical LAN adapter | |
networking.bridges.br0.interfaces = ["eth0"]; | |
# Example with gogs (VM name: projects) | |
containers.projects = { |
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
[annex]$ cat git-trace.log | |
12:49:27.838912 git.c:564 trace: exec: 'git-annex' 'webapp' | |
12:49:27.839054 run-command.c:336 trace: run_command: 'git-annex' 'webapp' | |
12:49:28.242593 git.c:351 trace: built-in: git 'config' '--null' '--list' | |
12:49:28.682977 git.c:351 trace: built-in: git 'show-ref' 'git-annex' | |
12:49:28.873175 git.c:351 trace: built-in: git 'show-ref' '--hash' 'refs/heads/git-annex' | |
12:49:28.911249 git.c:351 trace: built-in: git 'log' 'refs/heads/git-annex..e936fbcafa9895c8f1b5c9ca5b1afa9896f8a91b' '--pretty=%H' '-n1' | |
12:49:31.025794 git.c:351 trace: built-in: git 'cat-file' '--batch' | |
12:49:31.193102 git.c:351 trace: built-in: git 'show-ref' 'git-annex' | |
12:49:31.194723 git.c:351 trace: built-in: git 'show-ref' '--hash' 'refs/heads/git-annex' |
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 | |
hits = [] | |
checks = { | |
#'_spec\.rb$' => ['focus:[:space:]*true'], | |
'\.(rb|erb)$' => ['binding\.pry', 'debugger', 'byebug'] | |
} | |
# Find the names of all the filenames that have been (A)dded (C)opied or (M)odified | |
filenames = `git diff --cached --name-only --diff-filter=ACM`.split("\n") |
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
-- takes a PGM file and outputs an ASCII list of triplets (coordinates) | |
-- in order to import a kinect depth map in meshlab as a point cloud | |
import Data.Char(toLower) | |
main = interact pgm2triplets | |
pgm2triplets :: String -> String | |
pgm2triplets whole = unlines $ map showTriplet noHoles | |
where tokens=words whole | |
height=read$tokens!!2 :: Int |
NewerOlder