Skip to content

Instantly share code, notes, and snippets.

View scmanjarrez's full-sized avatar
🧠
hungry mind

Sergio C scmanjarrez

🧠
hungry mind
  • Spanish National Research Council (CSIC)
  • Madrid
View GitHub Profile
@scmanjarrez
scmanjarrez / fix.md
Last active February 3, 2024 11:24
Backup on how to ignore waiting for interfaces with optional: true in netplan (bug)
@scmanjarrez
scmanjarrez / install.sh
Created January 25, 2024 10:19
Install microsoft propietary fonts in linux (calibri, cambria, corbel, etc)
#!/bin/bash
TMPDIR=/tmp/msfonts
mkdir -p $TMPDIR
cd $TMPDIR
wget https://sourceforge.net/projects/mscorefonts2/files/cabs/PowerPointViewer.exe
cabextract -L -F ppviewer.cab -d . PowerPointViewer.exe
cabextract -L -F '*.TT[FC]' -d . ppviewer.cab
@scmanjarrez
scmanjarrez / HowToOTGFast.md
Created February 1, 2024 13:36 — forked from gbaman/HowToOTGFast.md
Simple guide for setting up OTG modes on the Raspberry Pi Zero, the fast way!

Setting up Pi Zero OTG - The quick way (No USB keyboard, mouse, HDMI monitor needed)

More details - http://blog.gbaman.info/?p=791

For this method, alongside your Pi Zero, MicroUSB cable and MicroSD card, only an additional computer is required, which can be running Windows (with Bonjour, iTunes or Quicktime installed), Mac OS or Linux (with Avahi Daemon installed, for example Ubuntu has it built in).
1. Flash Raspbian Jessie full or Raspbian Jessie Lite onto the SD card.
2. Once Raspbian is flashed, open up the boot partition (in Windows Explorer, Finder etc) and add to the bottom of the config.txt file dtoverlay=dwc2 on a new line, then save the file.
3. If using a recent release of Jessie (Dec 2016 onwards), then create a new file simply called ssh in the SD card as well. By default SSH i

@scmanjarrez
scmanjarrez / nmapBasic2Full.sh
Last active March 28, 2024 16:26
Small script to generate a list of ports to be scanned from the port detected by nmap
#!/bin/bash
declare -a tcp=()
declare -a udp=()
while IFS= read -r line; do
port=$(echo $line | awk '{print $4}')
[[ "$port" =~ "tcp" ]] && tcp+=("${port%%/*}") || udp+=("${port%%/*}")
done < "${1:-/dev/stdin}"
IFS=,
echo -n "-sS -p "
echo "${tcp[*]}"
@scmanjarrez
scmanjarrez / kali_dark.yaml
Created June 16, 2024 19:13
Kali-dark theme ported from qterminal to Alacritty (yaml)
# 0x From the Kali-dark Qterminal color palette
colors:
# 0x Default colors
primary:
background: '0x23252e' # Converted from Background Color 35,37,46
foreground: '0xffffff' # Converted from Foreground Color 255,255,255
# 0x Colors the cursor will use if `custom_cursor_colors` is true
cursor:
text: '0xbbbbbb' # Assuming the same as given