We are going to upload the file we want to distribute in the "public" Dropbox folder, then use that file's URL as the webseed for a new torrent. Then shut off our computer knowing that our file is well looked-after and you will not receive a stern email from Dropbox.
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
<form method="POST" data-async data-target=".result_div" data-cache="false" action="/process"> | |
<input type="text" id="field1" name="field1" placeholder="Field 1"> | |
<input type="text" id="field2" name="field2" placeholder="Field 2"> | |
<button type="submit" data-processing="¡ OK, SENDING !" data-processing-class="btn-warning" class="btn">¡ Go !</button> | |
</form> |
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
function ping(ip) { | |
var img = new Image(); | |
var start = new Date().getTime(); | |
var flag = false; | |
var isCloseWifi = true; | |
var hasFinish = false; | |
img.onload = function() { | |
if ( !hasFinish ) { |
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
<?php | |
$filetypes = array('jpg','jpeg','png','gif','bmp','tiff'); | |
$source = './images_unsorted'; | |
$target = './images_sorted'; | |
$iterator = new RecursiveDirectoryIterator($source); | |
$bytestotal = 0; | |
$nbfiles = 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
def prompt_with_default(var, default) | |
set(var) do | |
Capistrano::CLI.password_prompt "#{var} [#{default}] : " | |
end | |
set var, default if eval("#{var.to_s}.empty?") | |
end | |
namespace :misc do | |
desc "Remove problematic packages" | |
task :remove do |
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 | |
### BEGIN INIT INFO | |
# Provides: supervisord | |
# Required-Start: $remote_fs | |
# Required-Stop: $remote_fs | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Example initscript | |
# Description: This file should be used to construct scripts to be | |
# placed in /etc/init.d. |
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
extract () { | |
if [ -f $1 ] ; then | |
case $1 in | |
*.tar.bz2) tar xjf $1 ;; | |
*.tar.gz) tar xzf $1 ;; | |
*.bz2) bunzip2 $1 ;; | |
*.rar) unrar e $1 ;; | |
*.gz) gunzip $1 ;; | |
*.tar) tar xf $1 ;; | |
*.tbz2) tar xjf $1 ;; |
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
TMP_DIR="/tmp/issud/" | |
TMP_FILE="issuufile" | |
KONT=1 | |
I_MAGICK=0 | |
TITLE="" | |
if [ -z "$1" ]; then | |
echo "Script para descargar documentos de ISSUU" | |
echo "Usage: `basename $0` URL" | |
echo "" |
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/bash | |
# Get a list of all fragmented tables | |
FRAGMENTED_TABLES="$( mysql -e ';use information_schema; SELECT TABLE_SCHEMA,TABLE_NAME FROM TABLES WHERE ENGINE="MyISAM" AND TABLE_SCHEMA NOT IN ("information_schema","mysql") AND Data_free > 0' | grep -v "^+" | sed 's,\t,.,' )" | |
for fragment in $FRAGMENTED_TABLES; do | |
database="$( echo $fragment | cut -d. -f1 )" | |
table="$( echo $fragment | cut -d. -f2 )" | |
[ $fragment != "TABLE_SCHEMA.TABLE_NAME" ] && echo "Optimizando $fragment" && mysql -e "USE $database; OPTIMIZE TABLE $table;" > /dev/null | |
done |
OlderNewer