This file contains hidden or 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 | |
# @author Marcelo Haskell Camargo | |
EMAIL_FILE=".email.auth" | |
PASSWD_FILE=".passwd.auth" | |
AUTH_FILE=".auth" | |
trap "rm -f $EMAIL_FILE; exit" SIGHUP SIGINT SIGTERM | |
trap "rm -f $PASSWD_FILE; exit" SIGHUP SIGINT SIGTERM | |
trap "rm -f $AUTH_FILE; exit" SIGHUP SIGINT SIGTERM |
This file contains hidden or 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
{ | |
"name": "rung-client", | |
"version": "0.0.1", | |
"description": "Rung Client Desktop Linux x64", | |
"keywords": ["rung"], | |
"main": "https://app.rung.com.br/", | |
"window": { | |
"title": "Rung", | |
"icon": "rung.png", | |
"min_width": 700, |
This file contains hidden or 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
/** | |
* Groups a set of follow-up items based on: | |
* - Being a comment | |
* - Being the same author | |
* - The time difference between them in seconds is lesser than 30 | |
* | |
* @author Celão Camargo | |
* @type [{ value :: String, id :: String, date :: String }] -> {homomorphic} | |
* @param {Array} items | |
* @return {Array} |
This file contains hidden or 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
/*{Protheus.doc} Download | |
Download de arquivo via HTTP (SOAP, REST) | |
@type function | |
@author Marcelo Camargo | |
@since 14/03/2016 | |
@version P11/P12 | |
@param oWebService, object, instância do webservice | |
@param cPath, string, caminho e nome do arquivo a fazer download | |
@param cFileName, string, nome do arquivo de saída |
This file contains hidden or 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
@[ | |
Declare MaxAge: Nat Picture '99' := 100 { Max age to retrieve } | |
Declare Prop: Symbol := GENDER { Custom property to pick. Defaults to gender } | |
] | |
SELECT USER.NAME, | |
USER.EMAIL, | |
USER.@Prop | |
FROM dbo.TB_USERS | |
WHERE USER.AGE > @MaxAge |
This file contains hidden or 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
{ | |
var checkDuplication = function (list) { | |
var found = []; | |
list.forEach(function (item) { | |
if (found.indexOf(item.name) !== -1) { | |
throw new Error('Field `' + item.name + "' declared twice"); | |
} | |
found.push(item.name); | |
}); |
This file contains hidden or 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
set nocompatible | |
filetype off | |
" set the runtime path to include Vundle and initialize | |
set rtp+=~/.vim/bundle/Vundle.vim | |
set rtp+=/usr/local/lib/python2.7/dist-packages/powerline/bindings/vim/ | |
" Always show statusline | |
set laststatus=2 |
This file contains hidden or 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
public static boolean isPalindorme(String word) { | |
int ahead = 0; | |
int behind = word.length - 1; | |
while (behind > ahead) { | |
if (word[ahead] != word[behind]) { return false; } | |
ahead++; behind--; | |
} | |
return true; |
This file contains hidden or 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
MarxDown | |
= FuncCall | |
/ Ident | |
FuncCall "function call" | |
= invoke:Ident _ '(' _ expr:MarxDown _ ')' { | |
return { | |
type: 'FuncCall', | |
value: { | |
call: invoke, |
This file contains hidden or 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
module Main where | |
-- Written by Marcelo Camargo <[email protected]> on | |
-- Sat Oct 22 2016 | |
-- Represent natural numbers | |
data ℕ = Zero | |
| Succ ℕ | |
inc ∷ ℕ → ℕ | |
inc = Succ |