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
$ vim .profile | |
export JAVA_HOME=$(/usr/libexec/java_home) | |
$source .profile | |
$ echo $JAVA_HOME | |
/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home | |
$ /usr/libexec/java_home -V |
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
$ vim .profile | |
export M2_HOME=/Users/ryanpadilha/Documents/ambiente/apache-maven-3.3.9 | |
export M2=$M2_HOME/bin | |
export PATH=$M2:$PATH | |
$ source .profile | |
$ mvn -version | |
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T14:41:47-02:00) |
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
$ vim .bashrc | |
JAVA_HOME=/usr/lib/jvm/java-8-oracle | |
export PATH=$JAVA_HOME:$PATH | |
$ echo $JAVA_HOME | |
/usr/lib/jvm/java-8-oracle | |
# reload bashrc file | |
$ . .bashrc |
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
$ vim .bashrc | |
M2_HOME=/home/ryanpadilha/Documentos/ambiente/apache-maven-3.3.9/bin | |
export PATH=$M2_HOME:$PATH | |
$ mvn -version | |
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T14:41:47-02:00) | |
Maven home: /Users/ryanpadilha/Documents/ambiente/apache-maven-3.3.9 | |
Java version: 1.8.0_65, vendor: Oracle Corporation | |
Java home: /Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home/jre |
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 hi = hudson.model.Hudson.instance | |
hi.getItems(hudson.model.Job).each { | |
job -> | |
jobName = job.getFullDisplayName() | |
if (job.isBuilding()) { | |
println(".. job " + jobName + " is currently running, skipped") | |
return |
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
$ sudo gedit /usr/share/applications/eclipse-mars.desktop | |
# file eclipse-mars.desktop | |
# paste the lines and adjust the path application | |
[Desktop Entry] | |
Encoding=UTF-8 | |
Exec=/home/ryan/Documentos/ambiente/eclipse/eclipse | |
Icon=/home/ryan/Documentos/ambiente/eclipse/icon.xpm | |
Type=Application |
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
-- SQL command | |
SELECT CPAI.OWNER, CPAI.CONSTRAINT_NAME, CPAI.CONSTRAINT_TYPE, CPAI.TABLE_NAME, | |
CPAI.STATUS, CPAI.R_CONSTRAINT_NAME, COL.COLUMN_NAME, | |
( | |
SELECT F.TABLE_NAME FROM DBA_CONSTRAINTS F | |
WHERE F.CONSTRAINT_NAME = CPAI.R_CONSTRAINT_NAME | |
) TABLE_NAME_FILHA | |
FROM DBA_CONSTRAINTS CPAI, DBA_CONS_COLUMNS COL | |
WHERE CPAI.CONSTRAINT_NAME = COL.CONSTRAINT_NAME |
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
// método para serializar objeto em xml | |
public static string Serializar(object objeto) | |
{ | |
try | |
{ | |
StringBuilder writer = new StringBuilder(); | |
XmlSerializer serializer = new XmlSerializer(objeto.GetType()); | |
XmlSerializerNamespaces ns = new XmlSerializerNamespaces(); | |
ns.Add(String.Empty, 'http://www.portalfiscal.inf.br/nfe'); |
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
// declarando variaveis e enumerador necessarios | |
enum ResultadoAssinatura | |
{ | |
XMLAssinadoSucesso, | |
CertificadoDigitalInexistente, | |
TagAssinaturaNaoExiste, | |
TagAssinaturaNaoUnica, | |
ErroAssinarDocumento, | |
XMLMalFormado, | |
ProblemaAcessoCertificadoDigital |
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
<NFe xmlns="http://www.portalfiscal.inf.br/nfe" > | |
<infNFe Id="NFe31060243816719000108550000000010001234567897" versao="2.00"> | |
... | |
</infNFe> | |
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#"> | |
<SignedInfo> | |
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/> | |
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" /> | |
<Reference URI="#NFe31060243816719000108550000000010001234567897"> | |
<Transforms> |
OlderNewer