Skip to content

Instantly share code, notes, and snippets.

View kenshin6x's full-sized avatar

Junior Andrade kenshin6x

View GitHub Profile
export PS1="\[\033[38;5;47m\]\u\[$(tput sgr0)\]\[\033[38;5;15m\]@\[$(tput sgr0)\]\[\033[38;5;40m\]\h\[$(tput sgr0)\]\[\033[38;5;15m\]:\[$(tput sgr0)\]\[\033[38;5;6m\][\[$(tput sgr0)\]\[\033[38;5;9m\]\w\[$(tput sgr0)\]\[\033[38;5;6m\]]:\[$(tput sgr0)\]\[\033[38;5;15m\] \[$(tput sgr0)\]"
@kenshin6x
kenshin6x / tmux-cheatsheet.markdown
Created October 18, 2017 14:14 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@kenshin6x
kenshin6x / Sublime Text 3 Build 3103 License Key - CRACK
Created July 28, 2017 11:23
Sublime Text 3 Build 3103 License Key - CRACK
I use the first
—– BEGIN LICENSE —–
Michael Barnes
Single User License
EA7E-821385
8A353C41 872A0D5C DF9B2950 AFF6F667
C458EA6D 8EA3C286 98D1D650 131A97AB
AA919AEC EF20E143 B361B1E7 4C8B7F04
<database.default>
<dbType>pgsql</dbType>
<host>10.0.0.22</host>
<port>5432</port>
<user>pauser</user>
<senha>pauser</senha>
<db>creapa_corp_db</db>
<persistent>false</persistent>
</database.default>
<?php
/*
*
* Tupã - Sistema Corporativo.
* Copyright (C) 2010 Tecnotech Sistemas LTDA
*
* Este software é protegido pelas disposições da Lei 9.609/98
* Ficando os infratores sujeitos às penas dos crimes previstos no art. 12,
* sem prejuízo da responsabilidade civil pelos danos eventualmente causados
* pelo uso e distribuição de cópias não autorizadas do software ou por
<?xml version="1.0" encoding="UTF-8"?>
<config>
<org id="0 - Layout CREA-PAh">
<!-- INFORMAÇÕES DA ORGANIZAÇÃO -->
<sigla.org>CREA-PA</sigla.org>
<nome.org>Conselho Regional de Engenharia e Agronomia da Pará</nome.org>
<email.org>faleconosco@creapa.com.br</email.org>
<emailnoreply.org>naoresponda@creapa.com.br</emailnoreply.org>
<mailernoreply.org>naoresponda@creapa.com.br</mailernoreply.org>
<homepage.org>sitac.creapa.org.br</homepage.org>
@kenshin6x
kenshin6x / gist:8446248
Created January 15, 2014 22:44
faillgo sitac processo boletos
[Wed Jan 15 19:39:30 2014] [error] [client ::1] PHP Fatal error: Call to undefined method FiscalizacaoImpl::tramiteauto() in /Users/kenshin6x/Developer/tecnotechs_adapt/app/models/classes.bo/ReceitaBO.php on line 1294, referer: http://localhost:8080/tecnotechs_adapt/app/view/sight/main.php?form=ProcessarRetorno
[Wed Jan 15 19:39:30 2014] [error] [client ::1] PHP Stack trace:, referer: http://localhost:8080/tecnotechs_adapt/app/view/sight/main.php?form=ProcessarRetorno
[Wed Jan 15 19:39:30 2014] [error] [client ::1] PHP 1. {main}() /Users/kenshin6x/Developer/tecnotechs_adapt/app/controller/ReceitaController.php:0, referer: http://localhost:8080/tecnotechs_adapt/app/view/sight/main.php?form=ProcessarRetorno
[Wed Jan 15 19:39:30 2014] [error] [client ::1] PHP 2. ReceitaController->ReceitaController() /Users/kenshin6x/Developer/tecnotechs_adapt/app/controller/ReceitaController.php:5510, referer: http://localhost:8080/tecnotechs_adapt/app/view/sight/main.php?form=ProcessarRetorno
[Wed Jan 15 19:39:30 2014] [e
@kenshin6x
kenshin6x / gist:8429913
Last active January 3, 2016 07:29
ncmpcpp brew faillog
Juniors-MacBook-Pro:~ kenshin6x$ brew install ncmpcpp -v --HEAD
==> Cloning git://repo.or.cz/ncmpcpp.git
git --git-dir /Library/Caches/Homebrew/ncmpcpp--git/.git status -s
Updating /Library/Caches/Homebrew/ncmpcpp--git
git config remote.origin.url git://repo.or.cz/ncmpcpp.git
git config remote.origin.fetch +refs/heads/master:refs/remotes/origin/master
git fetch origin
git checkout -f master
Already on 'master'
git reset --hard origin/HEAD
@kenshin6x
kenshin6x / gist:5686969
Last active December 17, 2015 23:09
SQL - Radius - Relatório da quantidade de horas logado do usuário
select ra.username, ra.acctstarttime, ra.acctstoptime, (abs(extract(epoch from ra.acctstarttime - ra.acctstoptime) /3600)::int) as horas
from radacct as ra
where
ra.acctstarttime is not null
and ra.acctstoptime is not null
and abs(extract(epoch from ra.acctstarttime - ra.acctstoptime) /3600)::int > 5 -- quantidade de horas que voce quer
and to_char(ra.acctstarttime,'yyyymmdd') = '20130501'
order by ra.radacctid, ra.username desc
@kenshin6x
kenshin6x / forma_sql.py
Created March 25, 2013 03:49
Forma SQL
lines = tuple(open('file.txt', 'r'))
for l in lines:
s = l.split()
print "UPDATE iadmin_servicointernet set login_password_plain = '%s' WHERE clientecontrato_id = %s ;" \
%(s[0], s[1])