Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Fábio Gomes fabioxgn

🏠
Working from home
  • Leme, SP - Brazil
View GitHub Profile
@fabioxgn
fabioxgn / client.rb
Created Jun 1, 2021
Ruby TCP example
View client.rb
require "socket"
socket = TCPSocket.open("localhost", 6666)
loop do
input = gets.chomp #Ask client for command
socket.puts input # Send command to server
line = socket.gets #Get server response
puts line
@fabioxgn
fabioxgn / input-event.xml
Created May 17, 2020
Input Mouse event log
View input-event.xml
- <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
- <System>
<Provider Name="Microsoft-Windows-Kernel-Power" Guid="{331c3b3a-2005-44c2-ac5e-77220c37d6b4}" />
<EventID>507</EventID>
<Version>8</Version>
<Level>4</Level>
<Task>158</Task>
<Opcode>0</Opcode>
<Keywords>0x8000000000000604</Keywords>
<TimeCreated SystemTime="2020-05-17T14:13:12.704922700Z" />
@fabioxgn
fabioxgn / eos.md
Last active Sep 10, 2016
Passos para configurar uma nova máquina
View eos.md
@fabioxgn
fabioxgn / Project.dpr
Created Oct 1, 2015
Delphi XE7/10 Seattle DataSnap OpenSSL Access Violation
View Project.dpr
program Project1;
{$APPTYPE CONSOLE}
uses
System.SysUtils,
ServerContainerUnit1 in 'ServerContainerUnit1.pas' {ServerContainer1: TDataModule},
System.Classes,
Data.SqlExpr,
IPPeerServer,
View savon_debug.rb
c = Savon.client(wsdl: "WSDL_URL", log: true, log_level: :debug) do
convert_request_keys_to :none
pretty_print_xml :true
end
View auth.go
package main
import (
"encoding/base64"
"net/http"
"strings"
)
type handler func(w http.ResponseWriter, r *http.Request)
@fabioxgn
fabioxgn / gist:530d0f6ff2a7c791366e
Last active Oct 1, 2015
go get usar ssh em vez de https
View gist:530d0f6ff2a7c791366e
git config --global url."git@github.com:".insteadOf "https://github.com/"
@fabioxgn
fabioxgn / stop_all.bat
Created Jan 18, 2015
Para todos os serviços do windows com um determinado nome
View stop_all.bat
wmic service where "name like 'MondeServer%'" call stopservice
@fabioxgn
fabioxgn / encontrar_log_ativo.bat
Created Jan 14, 2015
Encontrar clientes com log ativo
View encontrar_log_ativo.bat
findstr /spin /c:"Enabled = True" *.sic
@fabioxgn
fabioxgn / gosublime_linux
Last active Aug 29, 2015
Configure GoSublime Linux
View gosublime_linux
Go to:
Preferences -> Package Settings -> GoSublime -> Settings – User
Add:
{
"env": {"GOPATH": "$HOME/go"}
}
Source: https://github.com/DisposaBoy/GoSublime/issues/310#issuecomment-33052953