Skip to content

Instantly share code, notes, and snippets.

View leoluz's full-sized avatar

Leonardo Luz Almeida leoluz

View GitHub Profile
#Crie um arquivo na raiz do repositório chamado .svnignore
#Adicione nesse arquivo os patterns de arquivos a serem ignorados. Ex.: *.class
#Execute o comando abaixo:
$svn propset svn:ignore -RF .svnignore .
#PS1 Não esqueça de commitar o arquivo .svnignore :)
#PS2 Um arquivo/diretório uma vez adicionado, não poderá mais ser ignorado
# a não ser que seja removido.
@leoluz
leoluz / Acessando BigWS com Python (suds).py
Created August 23, 2009 03:42
Accessing a SOAP-WS within python using suds
# Esse exemplo foi testado com o exercicio do capitulo 20
# do curso da Caelum (fj31)
#
# Para instalar a lib do suds faca como root:
# $sudo easy_install suds
# digite python no terminal para invocar o interpretador do python.
# Em seguida digite as seguintes linhas:
>>>from suds.client import Client
<property name="connection.datasource">jdbc/MeuDataSource</property>
http://wiki.locaweb.com.br/pt-br/Usando_GIT_na_Hospedagem_Linux
@leoluz
leoluz / gae_guestbook.py
Created May 30, 2010 00:53
google app engine quick example
import cgi
from google.appengine.ext import db
from google.appengine.api import users
from google.appengine.ext import webapp
from google.appengine.ext.webapp.util import run_wsgi_app
class Greeting(db.Model):
author = db.UserProperty()
content = db.StringProperty(multiline=True)
@leoluz
leoluz / remove_svn_dirs
Created August 12, 2010 20:19
Search and remove all .svn dirs from a local subversion repo
find . -type d -name .svn -exec rm -rf {} \;
@leoluz
leoluz / grepSVNRepo.sh
Created June 15, 2012 15:34
How to grep a svn repo ignoring .svn files
find . -not \( -name *.svn -prune \) -type f -exec grep -ril HelloWorld {} \;
@leoluz
leoluz / tab_remove.sh
Created June 15, 2012 15:45
Remove tab character from files
expand -t 4 "$1" > /tmp/expand.tmp
mv /tmp/expand.tmp "$1"
@leoluz
leoluz / gist:6318789
Created August 23, 2013 12:29
pricerow impex
$catalogVersion=catalogVersion(catalog(id[default='electronicsProductCatalog']),version[default='Online'])[unique=true,default='electronicsProductCatalog:Online']
INSERT_UPDATE PriceRow;$catalogVersion;unit(code);price;currency(isocode)[unique=true];channel(code)[unique=true];product(code,$catalogVersion)[unique=true]
;;pieces;20.00;USD;;107701
;;pieces;12.34;USD;"mobile";107701
;;pieces;15.00;USD;"desktop";107701
@leoluz
leoluz / gist:9087940
Created February 19, 2014 08:13
search for a string in jar/zip files
sudo find libdir/ -name "*.jar" -exec zipgrep -n "Your String Here" '{}' \;