Skip to content

Instantly share code, notes, and snippets.

View danilogco's full-sized avatar

Danilo Carolino danilogco

  • QFlash
  • Rio Claro-SP, Brasil
  • 20:27 (UTC -03:00)
View GitHub Profile
@danilogco
danilogco / test-doc-see-as-virus-by-clamav.txt
Created June 14, 2024 15:28 — forked from mikecastrodemaria/test-doc-see-as-virus-by-clamav.txt
A simple text file to be used as positive test for ClamAv virus scanner
X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*
@danilogco
danilogco / main.py
Created May 2, 2022 22:51 — forked from philippegirard/main.py
fastAPI sentry middleware
import sentry_sdk
from fastapi import FastAPI
sentry_sdk.init(
dsn="your_dns",
)
app = FastAPI()
@danilogco
danilogco / readme.md
Created February 24, 2022 20:20 — forked from ChriRas/readme.md
Set up default audio device on Ubuntu 20.04 LTS

Problem

I have a notebook connected to a port replicator. I want to use the build-in speakers and microfone and not the external ones. If I boot my notebook in my port replicator Ubuntu changes the devices to external.

Solution

  1. Find your internal speaker
pactl list short sinks
@danilogco
danilogco / license-badges.md
Created January 2, 2022 19:44 — forked from qvil/license-badges.md
License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • Badges are made with Shields.io.
  • This badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.  
  • 🇫🇷 Cette liste en français

Conventinal Commit Messages

See how a minor change to your commit message style can make a difference. Examples

Have a look at CLI util git-conventional-commits to ensure this conventions and generate changelogs

Commit Formats

Default

@danilogco
danilogco / gist:1adbcdaffa4400672436cabd83fa16fb
Last active April 24, 2021 19:47 — forked from mislav/gist:938183
Faraday SSL example
connection = Faraday::Connection.new('http://example.com') do |builder|
builder.request :url_encoded # for POST/PUT params
builder.adapter :net_http
end
# same as above, short form:
connection = Faraday.new 'http://example.com'
# GET
connection.get '/posts'
@danilogco
danilogco / github_desktop_ubuntu.sh
Last active October 6, 2023 05:46 — forked from berkorbay/github_desktop_ubuntu.md
To install Github Desktop for Ubuntu
wget https://github.com/shiftkey/desktop/releases/download/release-2.7.2-linux1/GitHubDesktop-linux-2.7.2-linux1.deb
sudo gdebi GitHubDesktop-linux-2.7.2-linux1.deb
wget -qO - https://packagecloud.io/shiftkey/desktop/gpgkey | sudo tee /etc/apt/trusted.gpg.d/shiftkey-desktop.asc > /dev/null
sudo sh -c 'echo "deb [arch=amd64] https://packagecloud.io/shiftkey/desktop/any/ any main" > /etc/apt/sources.list.d/packagecloud-shiftky-desktop.list'
sudo apt update
sudo apt install github-desktop
@danilogco
danilogco / clean.sh
Created November 20, 2020 03:23 — forked from Iman/clean.sh
Free up disk space on Ubuntu - clean log, cache, archive packages/apt archives, orphaned packages, old kernel and remove the trash
#!/bin/sh
#Check the Drive Space Used by Cached Files
du -sh /var/cache/apt/archives
#Clean all the log file
#for logs in `find /var/log -type f`; do > $logs; done
logs=`find /var/log -type f`
for i in $logs
@danilogco
danilogco / install-comodo-ssl-cert-for-nginx.rst
Created January 7, 2019 20:17 — forked from bradmontgomery/install-comodo-ssl-cert-for-nginx.rst
Steps to install a Comodo PositiveSSL certificate with Nginx.

Setting up a SSL Cert from Comodo

I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.

These are the steps I went through to set up an SSL cert.

Purchase the cert

@danilogco
danilogco / gist:682f21dd85ed9e3205e66be0a70559bb
Created August 21, 2018 16:48 — forked from tonymtz/gist:d75101d9bdf764c890ef
Uninstall nodejs from OSX Yosemite
# first:
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.*
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following:
# go to /usr/local/lib and delete any node and node_modules
cd /usr/local/lib
sudo rm -rf node*