Skip to content

Instantly share code, notes, and snippets.

View docker hub
#verveur
#https://hub.docker.com/_/postgres/
docker pull postgres
#https://hub.docker.com/_/nginx/
docker pull nginx
#https://hub.docker.com/_/drupal/
docker pull drupal
#https://hub.docker.com/_/debian/
docker pull debian
#https://hub.docker.com/_/php/
View arduino_led.ino
void setup() {
Serial.begin(9600);
pinMode(13, OUTPUT);
}
void loop() {
if (Serial.available() > 0) { // if there is data coming from the serial port
int data = (int)Serial.read(); // get that data and print it
Serial.println(data);
if (data == 1) { // do what you want with this data
digitalWrite(13, HIGH);
@DILL44
DILL44 / decompresition.sh
Last active Nov 30, 2015
mes logiciel linux
View decompresition.sh
###############sytem
sudo apt-get install vim htop git
###############hardware
sudo apt-get install fritzing arduino kicad
###############admin
sudo apt-add-repository 'deb http://liveusb.info/multisystem/depot all main'
wget -q -O - http://liveusb.info/multisystem/depot/multisystem.asc | sudo apt-key add -
sudo apt-get update
sudo apt-get install virtualbox testdisk multisystem gsmartcontrol netdiscover
sudo adduser "$USER" adm
@DILL44
DILL44 / bash
Last active Nov 27, 2015
Atelier PiNG Breil
View bash
#!/bin/bash
#Xubuntu 14.04
## for 16 Go
## 3Go /
## 2Go swap
## 5Go /opt
## 3Go /var
## 3Go /home
View fablabdoc.dtd
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!ELEMENT projet (name, description, Warning*, illustrations?, authors, fablab?, licence, attachement+, materials?, tools?, skills?, steps?, creationDate, lastModification, tags?)>
<!----------------------------- base elements ----------------------------->
<!ELEMENT name (#PCDATA)>
<!ELEMENT description (#PCDATA)>
<!ELEMENT media (image|video)>
<!ELEMENT image EMPTY>
View backupApt
#!/bin/bash
# recupère les programmes installés dans les logs de apt
configFile=$1
sudo gzip -Nd /var/log/apt/history.log.*
file=`egrep 'apt-get install' /var/log/apt/history.log*`
# transforme en une commade d'install
file=`echo $file | sed 's/\/var\/log\/apt\/history.log[.]\?[0-9]*:Commandline: apt-get install//g'`
@DILL44
DILL44 / php file for debug
Created Nov 29, 2012
write file for testing variable in a php file.
View php file for debug
$file=fopen("/path/to/the/file/test.txt", 'w+',true);
$content='';
foreach ($aray as $value){
$content.="id: ".$value."\n";
}
fwrite($file,$content);
fclose($file);
}
@DILL44
DILL44 / drupal update
Last active Oct 13, 2015
update for drupal on shared server
View drupal update
wget http://ftp.drupal.org/files/projects/drupal-7.18.zip &&
unzip drupal-7.18.zip &&
rm -R drupal-7.18/sites/ &&
cp -R sites/ drupal-7.18/ &&
mv drupal-7.18/ ../ &&
rm drupal-7.18.zip &&
mkdir ../backup &&
mv * ../backup/ &&
mv .htaccess ../backup/ &&
rm -R ../drupal-7.18/.git*&&
View InstallDopCom.sh
git clone git://github.com/DILL44/DopCom.git&&
mv DopCom/* . &&
mv DopCom/.git* . &&
rm -R DopCom &&
wget http://ftp.drupal.org/files/projects/drupal-7.19.zip &&
unzip drupal-7.15.zip &&
rm -R drupal-7.15/sites/&&
mv drupal-7.15/* . &&
mv drupal-7.15/.htaccess . &&
rm -R drupal-7.15* &&
View photo_mail
#!/bin/bash
mail=''
choix='4'
retardataire=0
nom_photo='photo'
sujet='votre photo'
corp='vote photo grace au programme <a href="https://gist.github.com/DILL44/bb18e0f028cb3c8c0c41">photo mail</a>'
clear
ligne_separation(){
You can’t perform that action at this time.