Skip to content

Instantly share code, notes, and snippets.

View josefigueredo's full-sized avatar
🚀

Jose Figueredo josefigueredo

🚀
View GitHub Profile
@hamidzr
hamidzr / sof-audio-setup-carbonx1.sh
Last active June 2, 2023 01:43
Lenovo Carbon X1 Gen 7 - Audio and microphone fix - https://wiki.archlinux.org/index.php/Lenovo_ThinkPad_X1_Carbon_(Gen_7) might be all you need.
#!/bin/bash
# README You probablyl don't need this script anymore. Please read the comments below to catch up.
## Description
# Lenovo Carbon X1 Gen 7 - Audio and microphone fix - kernel 5.3+ required.
# The script has only been tested for Arch and OpenSuse,
# Original thread: https://forums.lenovo.com/t5/Ubuntu/Guide-X1-Carbon-7th-Generation-Ubuntu-compatability/td-p/4489823
# Prereq: Install Linux 5.3 or newer
@rezkam
rezkam / remove_twitter_favorites.py
Created May 13, 2019 23:14
Remove likes (favorite) from your tweets using twitter API (Working with Python 3.5+)
"""
Remove likes (favorite) from your tweets using twitter API
you need to install twitter-client for python to use this code:
pip install python-twitter ( more info https://github.com/bear/python-twitter)
to use this you need to generate authntication tokens for your account
find more info on (https://developer.twitter.com/en/docs/basics/authentication/guides/access-tokens)
"""
import asyncio
Dependences:
sudo apt-get update
sudo apt-get install build-essential
apt-get install python-dev
sudo pip install -U setuptools
Steps:
download from https://mrjbq7.github.io/ta-lib/install.html
@crypticmind
crypticmind / README.md
Last active March 18, 2025 16:24
Setup lambda + API Gateway using localstack
@mholt
mholt / macapp.go
Last active May 1, 2025 04:32
Distribute your Go program (or any single binary) as a native macOS application
// Package main is a sample macOS-app-bundling program to demonstrate how to
// automate the process described in this tutorial:
//
// https://medium.com/@mattholt/packaging-a-go-application-for-macos-f7084b00f6b5
//
// Bundling the .app is the first thing it does, and creating the DMG is the
// second. Making the DMG is optional, and is only done if you provide
// the template DMG file, which you have to create beforehand.
//
// Example use:
@random-robbie
random-robbie / install_go_pi.sh
Created April 26, 2018 14:16
Install Go Lang 1.10.1 on Raspberry Pi 3
wget https://storage.googleapis.com/golang/go1.10.1.linux-armv6l.tar.gz
sudo tar -C /usr/local -xvf go1.10.1.linux-armv6l.tar.gz
cat >> ~/.bashrc << 'EOF'
export GOPATH=$HOME/go
export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin
EOF
source ~/.bashrc
@bastman
bastman / optionalToNullable.kt
Created January 31, 2018 10:39
Kotlin extension function to convert Java8 Optional<T> to Kotlin nullable T?
fun <T : Any> Optional<T>.toNullable(): T? {
return if (this.isPresent) {
this.get()
} else {
null
}
}
@thomasbnt
thomasbnt / code_colors_discordjs.md
Last active April 17, 2025 12:21
Code colors for embed discord.js

Here is an updated list of the colors that are currently implemented with a name. To using colors on discord.js, this is a typedef Colors, Colors.Aqua to get the Aqua color.

Name Int value Hex Code
Default 0 #000000
Aqua 1752220 #1ABC9C
DarkAqua 1146986 #11806A
Green 5763719 #57F287
DarkGreen 2067276 #1F8B4C
@eruvanos
eruvanos / README.md
Last active October 11, 2024 22:14
Simple mock server for testing using Flask

Mock server for testing using flask

License

MIT

Prepare

Install flask and requests to run this example.

@joelibaceta
joelibaceta / minimal_payment.java
Last active April 5, 2021 18:35
Ejemplos de creación de pagos con el del SDK para Java de MercadoPago
// Implementacion Minima de un Pago usando el SDK para Java de MercadoPago
//import com.mercadopago.MP;
//import org.codehaus.jettison.json.JSONArray;
//import org.codehaus.jettison.json.JSONObject;
MP mp = new MP("ACCESS_TOKEN");
JSONObject payment = null;
try {