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
# docker build -t bblanchon/domoticz . | |
# docker run --device /dev/ttyACM0 -p 80:8080 bblanchon/domoticz | |
FROM ubuntu:14.04 | |
MAINTAINER bblanchon | |
# install dependencies | |
RUN apt-get update && \ | |
apt-get install -y \ | |
build-essential \ |
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
find . -name '*.sh' | xargs git update-index --chmod=+x |
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
$ErrorActionPreference = "Stop" | |
Add-AzureAccount | |
Select-AzureSubscription -Name "Continuous Integration" | |
Write-Host 'The following VM instances are available:' | |
Get-AzureVM | foreach { $_.Name } | |
$vmName = Read-Host 'Enter the name of the VM to capture' | |
Write-Host 'The following VM images are available:' |
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
Add-AzureAccount | |
Select-AzureSubscription -SubscriptionName "Continuous Integration" | |
Get-AzureVM | Remove-AzureVM -DeleteVHD -Verbose |
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
find $(pwd) -type d | while read DIR | |
do | |
cd $DIR | |
FILES=$(find -maxdepth 1 -type f -not -name '*SUMS' -printf '"%f"\n' | sort) | |
FILE_COUNT=$(echo $FILES | wc -c) | |
if [ -z "$FILES" ] | |
then | |
rm -f *SUMS | |
else | |
echo $FILES | xargs md5sum > MD5SUMS |
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
void setup() { | |
Serial.begin(9600); | |
Serial.println("{\"sensor\":\"gps\",\"time\":1351824120,\"data\":[48.756080,2.302038]}"); | |
Serial.println("{\n \"sensor\": \"gps\",\n \"time\":1351824120,\n \"data\": [\n 48.756080,\n 2.302038\n ]\n}"); | |
} | |
void loop() { | |
// not used in this example |
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
void setup() { | |
Serial.begin(9600); | |
char json[] = | |
"{\"sensor\":\"gps\",\"time\":1351824120,\"data\":[48.756080,2.302038]}"; | |
const char* sensor = "gps"; | |
long time = 1351824120; | |
double latitude = 48.756080; | |
double longitude = 2.302038; |
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
Get-AzureStorageBlob -Container vhds | Where { $_.Name -like "*.status"} | Remove-AzureStorageBlob |
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
nm -U -j lib<mylib>.a | grep <myfunc> | c++filt |
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
# | |
# Automatically upgrade Ghost | |
# Benoit Blanchon 2014-2015 - MIT License | |
set -eu | |
GHOST_DIR=/var/www/blog.benoitblanchon.fr | |
function ghost_version { |