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
## List Docker CLI commands | |
docker | |
docker container --help | |
## Display Docker version and info | |
docker --version | |
docker version | |
docker info | |
## Execute Docker image |
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
sudo apt-get purge docker-ce | |
sudo rm -rf /var/lib/docker |
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
'use strict'; | |
const functions = require('firebase-functions'); | |
const admin = require('firebase-admin'); | |
const cors = require('cors') | |
console.log(process.env.NODE_ENV); | |
if (process.env.NODE_ENV === "production") { |
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 nome = "Thiago"; //global | |
let nomeLet = "Thiago"; //escopo/block | |
const nomeConst = "Thiago";//nao pode ser alterado | |
console.log(typeof ``); | |
var endereco = ""; | |
var endereco = "Thiago de Souza"; | |
var endereco = 'Thiago disse:"Eu sou eu!"'; | |
var endereco = "Thiago disse:\"Eu sou eu!\""; | |
var jardineiro = "Jesus" |
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
// ES2015 / TypeScript | |
import * as Swipe from '@swp/swipe-sdk' | |
// or via CommonJS | |
// const Swipe = require('@swp/swipe-sdk') | |
// initializes on production environment | |
const swp = Swipe.init({ | |
apiKey: "your api key", | |
secret: "your secret key", |
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
const Crypto = require("crypto-js") | |
const Base64 = require("crypto-js/enc-base64") | |
const requestPath = "/accounts" | |
const bodyString = "" | |
const secret = "71ad81f98fbbab22c9d74948d2899a65027208197291d11e2065c3a9c62fe1f0" | |
const timestamp = Math.floor(Date.now() / 1000) // "1540920260" | |
const method = "GET" | |
const stringToSign = method + timestamp + requestPath + bodyString | |
const hmac = Crypto.HmacSHA256(stringToSign, secret) |
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
// ES2015 / TypeScript | |
import * as Swipe from '@swp/swipe-sdk' | |
// or via CommonJS | |
// const Swipe = require('@swp/swipe-sdk') | |
// initializes on production environment | |
const swp = Swipe.init({ | |
apiKey: "your api key", | |
secret: "your secret key", |
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
export interface NewKycPerson { | |
type: KycType.PERSON | |
fullName: string | |
document: string | |
address: Address | |
birthDay: string | |
phone?: Phone | |
email?: string | |
} |
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
#local hosting | |
npm i -g serve | |
npm i -g http-server | |
#environment vars | |
npm install -g env-cmd | |
cat <<EOF >./.env | |
# This is a comment | |
ENV1=THANKS | |
ENV2=FOR ALL |
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
#https://en.wikipedia.org/wiki/Here_document#Unix_shells |