Skip to content

Instantly share code, notes, and snippets.

View fmoliveira's full-sized avatar

Filipe Oliveira fmoliveira

  • Level Access
  • Toronto
  • 23:51 (UTC -04:00)
View GitHub Profile
@fmoliveira
fmoliveira / Win11.md
Created May 13, 2026 02:53 — forked from wrmack/Win11.md
Windows 11 on MacBook M1

Windows 11 on MacBook M1 (ARM)

Steps I went through to install a Windows Insider Preview VHDX on a Macbook Pro using UTM. I needed Windows because I was developing an app to submit to the Microsoft Store. With the following setup I was able to develop an electron-based app and submit it to the Microsoft Store.

  1. Download the VHDX from Windows Insider Previews. You need to register for the Insider Program and sign in.
    • under Select edition select the Canary channel and press Confirm
    • select language and confirm
    • press Download
  2. Open UTM and press + to create a new virtual machine
    • Virtualize
  • Windows
@fmoliveira
fmoliveira / CustomDimension.java
Created July 1, 2024 02:06 — forked from DerFrZocker/CustomDimension.java
A simple class to change the dimension type of a world. For Spigot and Minecraft version 1.18.1.
/*
* MIT License
*
* Copyright (c) 2022 Marvin (DerFrZocker)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@fmoliveira
fmoliveira / dimension_codec.snbt
Created July 1, 2024 02:04 — forked from BomBardyGamer/dimension_codec.snbt
The default dimension codec, as of 1.17, as SNBT
{
"minecraft:dimension_type": {
type: "minecraft:dimension_type",
value: [
{
name: "minecraft:overworld",
id: 0,
element: {
piglin_safe: 0b,
natural: 1b,
@fmoliveira
fmoliveira / UNINSTALL-NIX-MACOS.md
Last active June 29, 2024 20:48
Nix uninstaller for macOS

Nix uninstaller for macOS

WARNING: USE AT YOUR OWN RISK!!! THIS SCRIPT IS UNMAINTAINED, NOT CONSIDERED STABLE, AND CAN BREAK YOUR SYSTEM!!! YOU HAVE BEEN WARNED!!!

Installing Nix is easy peasy, run a single command and you're ready to go.

But uninstalling it? Good luck hahahahahah!!!! You can try running the install program again and it will tell you what to do, but it is not quite complete. The best effort so far seems to be the uninstallation guide documented at: https://nix.dev/manual/nix/2.22/installation/uninstall

This gist contains two bash scripts tested a couple of times on macOS Sonoma running on Apple Sillicon with Nix 2.23.0. They are both based in the official macOS guide linked above with the intention of creating a "one command uninstall" experience that you might expect.

@fmoliveira
fmoliveira / MY-UBLOCK-FILTERS.md
Created April 13, 2024 14:20 — forked from supershadoe/MY-UBLOCK-FILTERS.md
Some uBlock₀ filters

Many of these filters are usually cosmetic instead of for blocking/skipping ads or something (Although some are used for that purpose like yt-filter)

To import a filter into Some uB₀, type the link https://gist.github.com/supershadoe/aed9db4c220b9150d2361a369f7be2f2/raw/{the filter to import, e.g., spotify; without the braces obviously}-ublock-filter.txt into uB₀ settings -> Filter lists -> Custom -> Import

Links to copy for filters (this may not be up to date)

Website Link
Spotify Spotify
@fmoliveira
fmoliveira / Kali Linux GUI on Termux Android.md
Created July 31, 2023 01:22 — forked from HimDek/Kali Linux GUI on Termux Android.md
This Guide will help you install Kali Linux in Android, that too with a GUI Desktop Environment within Android. It uses Termux to run Kali Linux in Android with XFCE4 Desktop Environment and a Tight VNC Server, which we connect to using a VNC Viewer app in Android.

How to install Kali Linux GUI Desktop in Android using Termux:

This Guide will help you install Kali Linux in Android, that too with a GUI Desktop Environment within Android. It uses Termux to run Kali Linux in Android with XFCE4 Desktop Environment and a Tight VNC Server, which we connect to using a VNC Viewer app in Android.

Just Follow these steps to install Kali Linux with XFCE4 Desktop GUI in Android using Termux:

  • Download and install Termux in Android. (Play Store release is no more updated, so is not recommended.)
  • Open Termux and run the following commands:
    apt update && apt install python python2 openssh -y
    

Build android app on termux

1. install termux

install termux from F-Droid.

2. setup termux

apt update
@fmoliveira
fmoliveira / functions.yaml
Created June 18, 2023 23:48 — forked from razor-x/functions.yaml
Sentry.io CloudFront Lambda@Edge tunnel
# TODO: Setup https://github.com/silvermine/serverless-plugin-cloudfront-lambda-edge
sentryOriginReq:
handler: handlers/handler.default
lambdaAtEdge:
distribution: AppDistribution
eventType: origin-request
includeBody: true
pathPattern: /_tunnel # TODO: Choose tunnel path.
@fmoliveira
fmoliveira / Complete.java
Created June 16, 2023 20:33 — forked from xudifsd/Complete.java
output of smali AST tree
package com.example;
public class Complete {
public int i;
private String s;
public Complete(int i, String s) {
this.i = i;
this.s = s;
}
@fmoliveira
fmoliveira / .yabairc
Created January 16, 2023 23:36 — forked from ChristopherBiscardi/.yabairc
What VSCode theme is that? youtube video
# the scripting-addition must be loaded manually if
# you are running yabai on macOS Big Sur. Uncomment
# the following line to have the injection performed
# when the config is executed during startup.
#
# for this to work you must configure sudo such that
# it will be able to run the command without password
sudo yabai --load-sa
yabai -m signal --add event=dock_did_restart action="sudo yabai --load-sa"