Skip to content

Instantly share code, notes, and snippets.

View fabiojose's full-sized avatar
🎯
Focusing

Fabio Jose fabiojose

🎯
Focusing
  • São Paulo, Brazil
  • 00:34 (UTC -03:00)
View GitHub Profile
@eyecatchup
eyecatchup / git-commit-log-stats.md
Last active May 16, 2024 16:50
Some commands to get git commit log statistics for a repository on the command line.

git commit stats

Commands to get commit statistics for a Git repository from the command line -
using git log, git shortlog and friends.




@steinwaywhw
steinwaywhw / One Liner to Download the Latest Release from Github Repo.md
Last active May 13, 2024 19:45
One Liner to Download the Latest Release from Github Repo
  • Use curl to get the JSON response for the latest release
  • Use grep to find the line containing file URL
  • Use cut and tr to extract the URL
  • Use wget to download it
curl -s https://api.github.com/repos/jgm/pandoc/releases/latest \
| grep "browser_download_url.*deb" \
| cut -d : -f 2,3 \
| tr -d \" \
@danielgross
danielgross / mathpix2gpt.py
Last active May 11, 2024 20:48
mathpix2gpt.py
import requests
import time
import os
import sys
import openai
import tiktoken
from termcolor import colored
openai.api_key = open(os.path.expanduser('~/.openai')).read().strip()
@hofmannsven
hofmannsven / README.md
Last active May 3, 2024 15:30
Git CLI Cheatsheet
@alexishida
alexishida / rtsp-intelbras-outros.txt
Last active April 5, 2024 17:34
RTSP dvr intelbras e outros
-------- Intelbras -------------------------------------------------------
rtsp://usuário:senha@ip:porta/cam/realmonitor?channel=1&subtype=0
-------- Luxvision -------------------------------------------------------
rtsp://ip:porta/user=[usuário]&password=[senha]&channel=1&stream=0.sdp
-------- Hikvision -------------------------------------------------------
rtsp://usuário:senha@ip:porta/Streaming/Channels/102
@textarcana
textarcana / git-log2json.sh
Last active March 1, 2024 05:26
Convert Git logs to JSON. The first script (git-log2json.sh) is all you need, the other two files contain only optional bonus features 😀THIS GIST NOW HAS A FULL GIT REPO: https://github.com/context-driven-testing-toolkit/git-log2json
#!/usr/bin/env bash
# Use this one-liner to produce a JSON literal from the Git log:
git log \
--pretty=format:'{%n "commit": "%H",%n "author": "%aN <%aE>",%n "date": "%ad",%n "message": "%f"%n},' \
$@ | \
perl -pe 'BEGIN{print "["}; END{print "]\n"}' | \
perl -pe 's/},]/}]/'
@ktosiu
ktosiu / ffmpeg_stream.md
Created August 25, 2020 09:11 — forked from docPhil99/ffmpeg_stream.md
Streaming FFmpeg and Python

This is running on Linux Mint

  1. Install ffmpeg
sudo apt-get install ffmpeg
  1. A simple test: open two terminals, in first run ffplay udp://127.0.0.1:23000 and in the second ffmpeg -i sample.mp4 -vcodec mpeg4 -f mpegts udp://127.0.0.1:23000 . This should play the video sample.mp4 although the quality is rather blocky.
@jonathansp
jonathansp / sptrans.py
Created November 15, 2013 20:50
Um cliente python para a API Olho Vivo da SPTrans de São Paulo
#!/usr/local/bin/python
# -*- coding: utf-8 -*-
""" Um cliente python para a API Olho Vivo """
import requests
class SPTransClient(object):
""" Um cliente python para a API Olho Vivo """
@ericchen
ericchen / gist:3081970
Created July 10, 2012 08:11
nodejs AES encrypt and decrypt
var crypto = require('crypto');
var AESCrypt = {};
AESCrypt.decrypt = function(cryptkey, iv, encryptdata) {
encryptdata = new Buffer(encryptdata, 'base64').toString('binary');
var decipher = crypto.createDecipheriv('aes-256-cbc', cryptkey, iv),
decoded = decipher.update(encryptdata);
@darrenpmeyer
darrenpmeyer / openconnect-7-ubuntu-build.md
Last active June 10, 2020 16:24
Building OpenConnect 7 on Ubuntu 14 (trusty), 15 (vivid), and 16 (xenial)