Skip to content

Instantly share code, notes, and snippets.

View pvoliveira's full-sized avatar

Paulo Oliveira pvoliveira

View GitHub Profile
@pvoliveira
pvoliveira / setup-ubuntu.sh
Created August 23, 2023 10:38
Setup Ubuntu WSL2
#! /usr/bin/bash
if ! which zsh > /dev/null; then
echo '## setup - zsh'
sudo apt-get update -y && sudo apt-get install -y zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
fi
if ! systemctl list-unit-files | grep 'wsl-vpnkit' > /dev/null; then
echo '## setup wsl-vpnkit'
@pvoliveira
pvoliveira / update-yuzu-deck.sh
Last active July 26, 2023 14:26
Script to update Yuzu EA on SteamDeck
# !/bin/bash
# download the new release
url=$(curl -L 'https://api.github.com/repos/pineappleEA/pineapple-src/releases/latest' \
| grep browser_download_url \
| cut -d '"' -f 4 \
| grep "Linux-Yuzu-EA-*")
#create the final name
finalname=$(basename $url | awk '{split($0,a,"-"); print "yuzu-ea-" a[4];}')
@pvoliveira
pvoliveira / ubuntu-20.04-wsl2.ps1
Created October 12, 2022 22:42 — forked from djfdyuruiry/ubuntu-20.04-wsl2.ps1
Ubuntu 20.04 in WSL 2
## change to your username
$user="wsl-user"
# download latest 20.04 release
curl --location `
--remote-name `
"https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64-wsl.rootfs.tar.gz"
# import into WSL 2
wsl --import `
@pvoliveira
pvoliveira / Makefile
Last active November 23, 2022 09:20
Scripts to compile WSL2 Kernel
.PHONY: build
build:
docker run --name wsl-kernel-builder --rm -it -v $(shell pwd):/scripts ubuntu:latest bash /scripts/script.sh

.NET Core 3.1.8 (CoreCLR 4.700.20.41105, CoreFX 4.700.20.41903), X64 RyuJIT

; Dotnetos.AsyncExpert.Homework.Module01.Benchmark.FibonacciCalc.Recursive(UInt64)
       push      rdi
       push      rsi
       push      rbx
       sub       rsp,20
       mov       rdi,rcx
       mov       rsi,rdx
       cmp       rsi,1
@pvoliveira
pvoliveira / .gitconfig
Last active August 24, 2020 09:35
.gitconfig
[gui]
[credential]
helper = manager
[http]
emptyAuth = true
[user]
name = Paulo Oliveira
email = paulovt7@gmail.com
[color "status"]
@pvoliveira
pvoliveira / pvoliveira_profiles.json
Created November 29, 2019 09:32
Profile - Windows Terminal
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"defaultProfile": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"profiles": [
{
"guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"hidden": false,
"name": "PowerShell Core",
# Ensure that Get-ChildItemColor is loaded
Import-Module Get-ChildItemColor
Import-Module DockerCompletion
# Set l and ls alias to use the new Get-ChildItemColor cmdlets
Set-Alias l Get-ChildItemColor -Option AllScope
Set-Alias ls Get-ChildItemColorFormatWide -Option AllScope
# Helper function to show Unicode characters

Keybase proof

I hereby claim:

  • I am pvoliveira on github.
  • I am pvoliveira (https://keybase.io/pvoliveira) on keybase.
  • I have a public key ASA8PfrXz25bSdbeG1X9i_7S4uOra8Dt4XHdCvP4zw-kCwo

To claim this, I am signing this object:

@pvoliveira
pvoliveira / boxstarter-work.ps1
Last active May 18, 2018 16:24
Boxstarter Command work machine
# Description: Boxstarter Script
# Author: Jess Frazelle <jess@linux.com>
# Last Updated: 2017-09-11
#
# Install boxstarter:
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force
#
# You might need to set: Set-ExecutionPolicy RemoteSigned
#
# Run this boxstarter by calling the following from an **elevated** command-prompt: