PNG
https://gist.github.com/assets/168240/25dd56cb-861f-4442-a6fb-b79e8c4afae4
# boot from live disk | |
# mount user partition | |
mount /dev/sda3 /mnt | |
# it might under a different location, such as | |
# mount /dev/nvme0n1p3 /mnt | |
# chroot into partition | |
arch-chroot /mnt |
i3-gaps | |
neofetch | |
gotop | |
cava | |
tty-clock | |
nvtop |
systemctl --user enable ssh-agent | |
systemctl --user start ssh-agent | |
eval "$(ssh-agent -s)" | |
ssh-add -l | |
# ssh config: https://gist.github.com/miguelmota/8151c9213c5d1de80423e26297db8636 |
sudo pacman -S mate mate-extra | |
sudo pacman -S lightdm lightdm-gtk-greeter | |
sudo systemctl enable lightdm | |
# optional | |
sudo pacman -S mate-themes | |
reboot | |
# to manually start DE with xinit |
# wipefs removes all filesystem signatures from the disk, including partition tables. | |
# This does not overwrite the actual data but removes metadata so the disk appears unformatted. | |
# If you want to securely wipe the disk, use a method like dd or blkdiscard. | |
sudo wipefs --all /dev/nvme0n1 | |
Using fdisk to prepare your disk for Arch Linux installation involves partitioning the disk as per your notes. Here’s a step-by-step guide: | |
Step 1: Start fdisk | |
Run fdisk on the target disk (e.g., /dev/sda): |
yay -S google-chrome | |
google-chrome-stable | |
yay -S google-chrome-canary | |
google-chrome-canary | |
yay -S google-chrome-dev | |
google-chrome-unstable | |
yay -S firefox |
import stringify from 'json-stable-stringify' | |
// Helper function to recursively sort arrays of objects | |
function sortNestedArrays(obj: any): any { | |
if (Array.isArray(obj)) { | |
return obj.map(sortNestedArrays).sort((a, b) => { | |
if (typeof a === 'object' && typeof b === 'object') { | |
return JSON.stringify(a).localeCompare(JSON.stringify(b)) | |
} | |
return 0 |
import fetch from 'node-fetch' | |
const username = 'UserNameGoesHere'; // Replace with the npm username | |
const npmAPI = `https://registry.npmjs.org/-/v1/search?text=maintainer:${username}&size=100` | |
async function getPackages() { | |
const response = await fetch(npmAPI) | |
const data = await response.json() | |
return data.objects.map(pkg => pkg.package.name) | |
} |
// run: mitmproxy -p 8080 | |
// run: node proxy.js | |
async function setupProxy (proxyUrl) { | |
// require('global-agent/bootstrap') | |
// process.env.GLOBAL_AGENT_HTTP_PROXY = proxyUrl | |
// process.env.GLOBAL_AGENT_HTTPS_PROXY = proxyUrl | |
// console.log('Global proxy routing set up.') | |
process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0' // Ignore self-signed certs, use with caution |