Enter this in the search box along with your search terms:
Get all gists from the user santisbon.
user:santisbon
Find all gists with a .yml extension.
extension:yml
Find all gists with HTML files.
language:html
| import React from 'react'; | |
| import { useForm } from "react-hook-form"; | |
| import { Dialog, DialogTitle, DialogContent, TextField, DialogContentText, Typography, DialogActions, Button, FormControl, FormLabel, FormGroup, makeStyles, Theme, createStyles, Box, CircularProgress, FormControlLabel, Checkbox } from '@material-ui/core'; | |
| import dynamic from 'next/dynamic'; | |
| const InputMak = dynamic( | |
| () => import('../../util/InputMak'), | |
| { loading: () => <p>...</p>, ssr: false } | |
| ); |
| import * as util from "util"; | |
| import { Context, Callback, SQSEvent } from "aws-lambda"; | |
| import SaldoNegocio, { ISQS_DATA } from "/opt/core/dist/SaldoNegocio"; | |
| import { TransactWriteItemList } from "aws-sdk/clients/dynamodb"; | |
| const DEBUG = true; | |
| export const handler = async ( event: SQSEvent ): Promise<void> => |
| /// | |
| /// Autocomplete Cliente | |
| /// | |
| const memoBuscarClientes = React.useMemo( () => | |
| { | |
| return _.throttle( | |
| ( sugestao:string, callback: (lst:string[])=>void ) => | |
| { | |
| new Promise((resolv: (lst:string[])=>void, rejec) => | |
| { |
| #!/bin/bash | |
| chmod 644 /var/log/syslog | |
| apt-get update && apt-get upgrade -y | |
| # TOOLS | |
| apt -y install git git-flow | |
| apt -y install zip | |
| apt -y install awscli |
| /** | |
| * A classe é exportada (via webpack) e inciada em 'window.objUsuarioCognito' | |
| * | |
| * Exemplos: | |
| * objUsuarioCognito.EhLogado(); // Retorna True no caso do usuário ter token armaznado, indicando que ele já executou o login. | |
| * | |
| * objUsuarioCognito.Login(); // Redireciona para o login (Amazon Hosted-UI - guarda o endereço local para o retorno do visitante). | |
| * | |
| * objUsuarioCognito.AtualizarToken() | |
| * .then( tokens => console.log(tokens)) // True => token atualizado com sucesso |
| #!/bin/bash | |
| apt-get -y update | |
| cat > /tmp/subscript.sh << EOF | |
| # START UBUNTU USERSPACE | |
| echo "Setting up NodeJS Environment" | |
| curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.9/install.sh | bash | |
| echo 'export NVM_DIR="/home/ubuntu/.nvm"' >> /home/ubuntu/.bashrc | |
| echo '[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm' >> /home/ubuntu/.bashrc | |
| # Dot source the files to ensure that variables are available within the current shell | |
| . /home/ubuntu/.nvm/nvm.sh |
Enter this in the search box along with your search terms:
Get all gists from the user santisbon.
user:santisbon
Find all gists with a .yml extension.
extension:yml
Find all gists with HTML files.
language:html
| export interface IConfig | |
| { | |
| API_KEY: string | |
| API_SECRET: string | |
| paypal_contexto: Paypal_AppContext | |
| } | |
| export interface Paypal_AppContext | |
| { |
| import * as util from "util"; | |
| import appConfig from "../app-config"; | |
| import * as AWS from 'aws-sdk'; | |
| import { InputLogEvent, Tags } from "aws-sdk/clients/cloudwatchlogs"; | |
| const DEBUG = false; | |
| export enum CWLogTipo { | |
| INFO = "INFO", |
| { | |
| "agent": { | |
| "run_as_user": "cwagent", | |
| "metrics_collection_interval": 300 | |
| }, | |
| "metrics": { | |
| "metrics_collected": { | |
| "mem": { | |
| "measurement": ["mem_used_percent"] | |
| }, |