Skip to content

Instantly share code, notes, and snippets.

View filipenevola's full-sized avatar

Filipe Névola filipenevola

View GitHub Profile
@sukharevd
sukharevd / wildfly-install.sh
Last active July 2, 2024 07:55
Script to install JBoss Wildfly 10.x as service in Linux
#!/bin/bash
#title :wildfly-install.sh
#description :The script to install Wildfly 10.x
#more :http://sukharevd.net/wildfly-8-installation.html
#author :Dmitriy Sukharev
#date :2016-06-18T02:45-0700
#usage :/bin/bash wildfly-install.sh
#tested-version1 :10.0.0.CR3
#tested-distros1 :Ubuntu 15.10; Debian 7,8; CentOS 7; Fedora 22
#tested-version2 :10.0.0.Final
@filipenevola
filipenevola / gist:23fd1cf371a584ef0fc7
Last active September 23, 2021 18:33
Vagas Java Desenvolvimento TecSinapse
// ==UserScript==
// @name TS - Copy TP US title/id
// @namespace br.com.tecsinapse
// @include https://tecsinapse.tpondemand.com/*
// @version 1.0.5
// @grant GM_setClipboard
// ==/UserScript==
function formatInfo(usId, usTitle) {
return '[' + usId + '] ' + usTitle;
@filipenevola
filipenevola / Javascript.xml
Last active April 8, 2017 20:01
Live Templates for Meteor & Javascript for WebStorm
<templateSet group="JavaScript">
<template name="cl" value="console.log(`$VAR$=${$VAR$}`);&#10;$END$" description="console.log" toReformat="true" toShortenFQNames="true">
<variable name="VAR" expression="" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JS_STATEMENT" value="true" />
</context>
</template>
<template name="cll" value="console.log(`$VAR$=${$VAR$}, $VAR2$=${$VAR2$}`);&#10;$END$" description="console.log 2 objects" toReformat="true" toShortenFQNames="true">
<variable name="VAR" expression="" defaultValue="" alwaysStopAt="true" />
<variable name="VAR2" expression="" defaultValue="" alwaysStopAt="true" />
@filipenevola
filipenevola / monitoring.js
Last active June 13, 2017 20:57
Google Script to Monitor Websites (like pingdom) and maybe restart the server
// spreadsheet attached as csv just for example
var sheet = SpreadsheetApp.getActiveSheet(),
startRow = 2, // skips header line
lastRow = sheet.getLastRow() -1, // get last line with data
dataRange = sheet.getRange(startRow, 1, lastRow, 6), // first value is the row, second is the column in number
data = dataRange.getValues(); // get data of every cell within the range
var FOOTER = "<br/><br/><a href=\"https://script.google.com/macros/d/MlurQVKrLcdi-mMWhhh3KoQL0bBO3PCUx/edit?uiv=2&mid=ACjPJvGlhxliD17ZP1feshkqGxfbplgytbuk6ZUR4bCV3Wt2ChtUk_rI3XArfC1JTrz4lhUmJpwICfja09S1tR1YRkS03LIgjPNmk7d7sjI1PUibdnPY_BNZr6E5Z_mJ1LWVam3p0lX9xps\">editar script</a>";
function checkAllSites() {
var nao = "NÃO";
@bvaughn
bvaughn / index.md
Last active April 3, 2024 07:41
Interaction tracing with React

This API was removed in React 17


Interaction tracing with React

React recently introduced an experimental profiler API. After discussing this API with several teams at Facebook, one common piece of feedback was that the performance information would be more useful if it could be associated with the events that caused the application to render (e.g. button click, XHR response). Tracing these events (or "interactions") would enable more powerful tooling to be built around the timing information, capable of answering questions like "What caused this really slow commit?" or "How long does it typically take for this interaction to update the DOM?".

With version 16.4.3, React added experimental support for this tracing by way of a new NPM package, scheduler. However the public API for this package is not yet finalized and will likely change with upcoming minor releases, so it should be used with caution.

@filipenevola
filipenevola / local-replica-set-with-oplog.md
Last active October 31, 2018 14:00 — forked from richsilv/local-replica-set-with-oplog.md
Setting up a local MongoDB 4.0.x replica set with oplog for use with Meteor

From an appropriate location:

mkdir -p /srv/mongodb/rs0-0 /srv/mongodb/rs0-1 /srv/mongodb/rs0-2
mongod --port 27018 --dbpath /srv/mongodb/rs0-0 --replSet rs0 --smallfiles --oplogSize 128 &
mongod --port 27018 --dbpath /srv/mongodb/rs0-1 --replSet rs0 --smallfiles --oplogSize 128 &
mongod --port 27019 --dbpath /srv/mongodb/rs0-2 --replSet rs0 --smallfiles --oplogSize 128 &
mongo --port 27017
@filipenevola
filipenevola / must-have.md
Created January 20, 2019 13:57
must have