Skip to content

Instantly share code, notes, and snippets.

View djalmaaraujo's full-sized avatar
🌊
Working from home

Djalma Araújo djalmaaraujo

🌊
Working from home
View GitHub Profile
@djalmaaraujo
djalmaaraujo / workshop.md
Last active August 29, 2016 19:41
UI Workshop

1. Exercício

  • 1 - Criar pastas css, template no diretório src
  • 2 - Criar o arquivo portal_normal.ftl na pasta template
  • 3 - Criar o _custom.scss na pasta css

2. Modificação e Criação do NavBar

  • 2.0 Modificar BG do Body
@djalmaaraujo
djalmaaraujo / gist:8cc6bbeb61755bbe76d19ccaf62fff0a
Created November 22, 2016 01:59 — forked from sowenjub/gist:1033876
Quickly dump your heroku production database and load it locally
#!/bin/bash
# This script does the following:
# 1/ capture and download the latest backup
# 2/ load it to your local database
# 3/ run your app and open Safari
# Just replace any uppercase string with your own data
#
@djalmaaraujo
djalmaaraujo / link
Created November 16, 2017 14:59
link
@djalmaaraujo
djalmaaraujo / android_app_build.gradle
Last active March 21, 2018 21:06
React Native Geolocation Module
compile(project(':react-native-geolocation-service')){
exclude group: 'com.google.android.gms' // this is important
}
compile ("com.google.android.gms:play-services-base:11.0.0") {
force = true;
}
compile ("com.google.android.gms:play-services-location:11.0.0") {
force = true;
}
@djalmaaraujo
djalmaaraujo / nightmare-on-amazon-linux.MD
Created June 4, 2018 23:54 — forked from dimkir/nightmare-on-amazon-linux.MD
How to run nightmare on Amazon Linux

Running nightmare on Amazon Linux

You may have thought of running nightmare on AWS Lambda. But before we can run it on Lambda, we need first to make it run on Amazon Linux.

Provision instance which replicates Lambda environment

According to AWS Documentation on Lambda Execution Environment and available Libraries we would need this AMI image with this alias amzn-ami-hvm-2016.03.3.x86_64-gp2. Keep in mind that AMI-image-id for this instance would be different in different regions (eg):

  • In eu-west-1 - ami-f9dd458a
  • In us-east-1 - ami-6869aa05
const shuffle = (array) => {
var currentIndex = array.length, temporaryValue, randomIndex;
// While there remain elements to shuffle...
while (0 !== currentIndex) {
// Pick a remaining element...
randomIndex = Math.floor(Math.random() * currentIndex);
currentIndex -= 1;
ADVALOR DTVM LTDA - 979
AGORA CTVM S/A - 39
ALFA CCVM S.A. - 4
AMARIL FRANKLIN CTV LTDA. - 226
ATIVA INVESTIMENTOS S.A. CTCV - 147
BANCO ANDBANK (BRASIL) S.A. - 4.002
BANCO BNP PARIBAS BRASIL S/A - 251
BANCO CITIBANK - 1.116
BANCO DAYCOVAL - 359
BANCO MODAL - 683
@djalmaaraujo
djalmaaraujo / papel_toalha.md
Last active August 22, 2019 18:19
Enxugue sua empresa com um papel toalha.

Como ter uma empresa enxuta e eficiente?

Sem papel.

E não estamos falando apenas de melhorar o meio ambiente, estamos falando de sermos eficientes sem precisar de coisas físicas.

Sem ilhas de informação.

Independente do que você faz, você precisa se comunicar com seus parceiros, clientes etc. Além disso, você precisa guardar suas informações em um único lugar, seguro e de fácil acesso. É aí que entram ferramentas como Google drive, atreladas à uma conta empresarial onde você pode ter seus e-mails, arquivos, calendario, reuniões, tudo em um único lugar. Essas ferramentas do mercado te dão acesso via computador, celular, tablet, etc.

@djalmaaraujo
djalmaaraujo / recife_nfse.js
Created October 8, 2019 02:17
Emissão Nota Fiscal Prefeitura do Recife - Puppeteer (wip)
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch({
headless: false,
});
const page = await browser.newPage();
const userData = {
login: 'x',
# Retorna dados sobre o pregão
http://www.bmfbovespa.com.br/Pregao-Online/ExecutaAcaoCarregarDados.asp?CodDado=IBOV,ticker&CA=undefined
# Retorna ações e seus últimos valores negociados
http://www.bmfbovespa.com.br/Pregao-OnLine/ExecutaAcaoCarregarDados.asp?CodDado=Ticker
# Retorna o histórico do dia de um papel
http://www.bmfbovespa.com.br/Pregao-Online/ExecutaAcaoCarregarDadosPapeis.asp?CodDado=petr4
# Retorna dados de um papel