I hereby claim:
- I am vhogemann on github.
- I am vhogemann (https://keybase.io/vhogemann) on keybase.
- I have a public key ASA_DuDI3YD6ZS9-IW0PaaZvm-8G0teGzybzSob-JYRsbwo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
namespace Test | |
module RandomPort = | |
open System | |
open System.Net.NetworkInformation | |
let isFree port = | |
let props = | |
IPGlobalProperties.GetIPGlobalProperties() | |
let tcpListeners = | |
props.GetActiveTcpListeners() |
//@ts-check | |
const fs = require("fs"); | |
const axios = require("axios").default; | |
let bearerToken = process.env.TWITTER_BEARER_TOKEN; | |
const headers = { 'Authorization': `Bearer ${bearerToken}` }; | |
const client = axios.create({baseURL : 'https://api.twitter.com/1.1/tweets/search/', headers : headers}) |
/** | |
* Use like *ngFor="let key of ( object | keys )" | |
*/ | |
@Pipe({ name: 'keys', pure: false }) | |
export class KeysPipe implements PipeTransform { | |
transform(value: any, args: any[] = null): any { | |
if(!value) return []; | |
return Object.keys(value); | |
} | |
} |
export function Debounce(wait: number) { | |
return function (target: any, propertyKey: string, descriptor: PropertyDescriptor) { | |
let timeout; | |
const original:Function = descriptor.value; | |
const debounced = function() { | |
const context = this; | |
const args = arguments; | |
const later = function() { | |
timeout = null; | |
original.apply(context, args); |
#! /bin/bash | |
# String retornada pelo reg.exe em caso de update com sucesso | |
REG_UP_OK="The operation completed successfully" | |
# Checa se existe lista de hosts não atualizados | |
if [ -e mortos.txt ]; then | |
# Se existe, renomeia para tmp.txt e o utiliza... | |
# criando uma nova lista para as maquinas que não atualizarem | |
mv mortos.txt tmp.txt | |
HOST_LIST="tmp.txt" | |
else |