Skip to content

Instantly share code, notes, and snippets.

View ivansabik's full-sized avatar

Iván ivansabik

  • Americas
View GitHub Profile
@ivansabik
ivansabik / cronScriptExample.php
Last active August 29, 2015 14:12
Command line periodic script with PHP
#!/usr/bin/php
<?php
while(true) {
sleep(5);
echo 'aufgewacht' . PHP_EOL;
}
?>
@ivansabik
ivansabik / csv_split.sh
Created June 9, 2014 15:39
Split CSV to multiple files with Shell script
#!/bin/bash
tail -n +2 CONSO.txt | split -l 20000000 - split_
for file in split_*
do
head -n 1 CONSO.txt > tmp_file
cat $file >> tmp_file
mv -f tmp_file $file
done