- strace :
sytemcall tracer
:Traces system call summoned by a process from syscall table
System calls, Eg:
open syscall (__NR_open),
kill syscall (__NR_kill),
getdents64 syscall (__NR_getdents64),
#!/usr/bin/env python3 | |
# This script will check for commands that you could most easily contribute to tldr (https://tldr.sh/) | |
# Run it in the root of the https://github.com/tldr-pages/tldr repository | |
import os | |
import sys | |
def get_used_commands(): | |
used_cmds = {} | |
for filepath, complex in {"~/.zsh_history": True, "~/.bash_history": False}.items(): | |
with open(os.path.expanduser(filepath), "rb") as file: |
FROM debian | |
RUN apt-get update && apt-get install -y git xz-utils python3 curl && rm -rf /var/lib/apt/lists/* | |
RUN git clone https://github.com/emscripten-core/emsdk.git && cd /emsdk && ./emsdk install latest-arm64-linux && ./emsdk activate latest-arm64-linux | |
ENTRYPOINT ["/emsdk/docker/entrypoint.sh"] |
# rm -rf but with safeguards, and cd into the directory | |
# You should put this in a sourced script (e.g .bashrc, .zshrc, etc...) | |
RED="\e[1;31m" | |
ORANGE="\e[38;5;208m" | |
GREEN="\e[38;5;2m" | |
RESET="\e[0;0m" | |
function initdir() { | |
if [ $# -eq 0 ]; then |
# license: CC0 / public domain | |
# https://gist.github.com/iTrooz/4dd70aea9debf80a59f3491601b40a26 | |
# feel free to use ! | |
name: TMate | |
on: | |
workflow_dispatch: | |
inputs: | |
runner: |
This is a collection of the tweaks and modification I've made to my Arch Linux installation over the months. These may be applicable to other distros, but please check first before doing anything. I also included Arch Wiki references for all the procedures I mentioned. My recommendation is not to blindly follow this gist but to always check with the Arch Linux wiki first. Things move fast and by the time you're reading this my gist may be out of date. Lastly, the golden rule: never execute a command you don't understand.
My current DE of choice is KDE's Plasma. I find it just about perfect.
There are various ways to install it on Arch. The most popular one is to install plasma
and plasma-applications
, but I don't like doing that because it comes with too many programs I'll never use. I, instead, install the base plasma
group, remove the few extra packages that come with it, then I finish off by installing a few KDE apps that don't come with th
msys2 vs msys vs msysgit | |
MinGW doesn't provide a linux-like environment, that is MSYS(2) and/or Cygwin | |
Cygwin is an attempt to create a complete UNIX/POSIX environment on Windows. | |
MinGW is a C/C++ compiler suite which allows you to create Windows executables - you only | |
need the normal MSVC runtimes, which are part of any normal Microsoft Windows installation. | |
MinGW provides headers and libraries so that GCC (a compiler suite, | |
not just a "unix/linux compiler") can be built and used against the Windows C runtime. |
#!/usr/bin/env python3 | |
# _*_ coding:utf-8 _*_ | |
import ctypes | |
import os | |
from ctypes import windll, wintypes | |
from typing import Optional | |
NULL: int = 0 |
#!/usr/bin/env bash | |
# set -x | |
if [[ $EUID -ne 0 ]]; then | |
echo "You must be root to run this script" | |
exit 1 | |
fi | |
# Returns all available interfaces, except "lo" and "veth*". |
from PyQt5.QtCore import * | |
from PyQt5.QtWidgets import * | |
from itertools import count, islice | |
class Threaded(QObject): | |
result=pyqtSignal(int) | |
def __init__(self, parent=None, **kwargs): | |
super().__init__(parent, **kwargs) |