Skip to content

Instantly share code, notes, and snippets.

View fredguth's full-sized avatar

Fred Guth fredguth

  • Brasília, DF, Brazil
View GitHub Profile
fredguth /
Last active December 18, 2023 21:05 — forked from denguir/
Installation procedure for CUDA & cuDNN

How to install CUDA & cuDNN on Ubuntu 22.04

Install NVIDIA drivers

Update & upgrade

sudo apt update && sudo apt upgrade

Remove previous NVIDIA installation

fredguth / registro_igreja_alema.pdf
Last active September 14, 2023 12:23
Familien-stammburch Guth
View registro_igreja_alema.pdf
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
fredguth / knapsack_breadth_first_search
Created July 13, 2023 20:33 — forked from pedrohbtp/knapsack_breadth_first_search
implementation of knapsack problem exploring the state space in a breadth first search manner and using memoization to reduce the exploration space
View knapsack_breadth_first_search
fredguth / zsh
Created September 30, 2022 13:46
batch transform pdfs to pngs in mac osx
View zsh
for file in *.pdf; do sips -s format png "$file" --out "${file%.pdf}.png"; done ▼ at 10:43:40
fredguth / gist:3d8b0c2beacd28e3c02ec41b54049fa7
Created August 17, 2022 15:04
Transfer issues between repos in Github
View gist:3d8b0c2beacd28e3c02ec41b54049fa7
gh issue transfer <issue ID> <destination repo>
So a few shell pipes later and we have this:
gh issue list -s all -L 500 --json number | \
jq -r '.[] | .number' | \
xargs -I% gh issue transfer %<destination repo>
fredguth / gist:0cdc40f573888b0b0faebec683a09ddf
Created April 11, 2022 13:22
Install node v6.9.1 in Mac M1 / Rosetta 2 updater install in mac m1
View gist:0cdc40f573888b0b0faebec683a09ddf
softwareupdate --install-rosetta --agree-to-license
grep RosettaUpdateAuto.pkg /var/log/install.log
#open RosettaUpdateAuto in the found folder
# go to in finder and click in Get Info (right click)
#click in open with rosetta
# open terminal
#should show intel i386
# now you can install nvm install v6.9.1
nvm install v6.9.1
View Proxmox
## login
get address in terminal and open in browser
## source lists
rm /etc/apt/sources.list.d/pve-enterprise.list
root@pve:/etc/apt/sources.list.d# nano pve-no-subscription.list
deb bullseye pve-no-subscription
fredguth / gist:de1c616f7b6e366d9d8b6e408ad97e80
Created October 27, 2021 13:35
Installing MinionPro on tex-live 2021
View gist:de1c616f7b6e366d9d8b6e408ad97e80
I recently spent a unimaginable amount of time installing MinionPro to use with latex. Here is how I eventually did it:
1) installed text-live 2021 full, the limited no-gui version did not work:
brew install --cask mactex
brew install lcdf-typetools
2) convert Minion otf files into the format text wants it.
git clone git\
cd FontPro
cp -r $path-to-otf-files .
# The files are now in a otf dir inside FontPro dir
sudo su
View gist:15a448c36b90ffb628509f36c483f3ee
Instead of using brew to install gpg, installed GPG Tools
add "/usr/local/MacGPG2/bin/" to path or alias gpg to /usr/local/MacGPG2/bin/gpg2
follow instructions
fredguth / icpbrasil.txt
Created October 27, 2019 20:38
Resolvendo alerta de sites não confiáveis nos sites do governo brasileiro
View icpbrasil.txt
É uma vergonha, mas o ICP-Brazilv5 foi lançado em 2016 e até hoje um Chrome ou Safari atualizado ainda não reconhece a cadeira de certficação brasileira.
No site do ITI, há uma explicação para quem tem Windows.
Para quem tem Mac, aqui a solução:
1) Baixar os certificados raiz do ICP Brasil em:
2) Após baixar, clique duplo para instalar.
3) No software Keys (Acesso às chaves), encontre os certificados de Autoridade Certificadora Raiz Brasileira e, em cada um deles, dê um clique duplo
4) abra a aba "Confiança" e altere "Ao usar este certificado" para "Confiar sempre"