Skip to content

Instantly share code, notes, and snippets.

# frozen_string_literal: true
require "bundler/inline"
gemfile(true) do
source "https://rubygems.org"
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
ruby "2.7.2"
@iximiuz
iximiuz / ethsend.py
Last active December 28, 2024 23:14
Send Ethernet frames from Python.
#!/usr/bin/env python3
# Usage: ethsend.py eth0 ff:ff:ff:ff:ff:ff 'Hello everybody!'
# ethsend.py eth0 06:e5:f0:20:af:7a 'Hello 06:e5:f0:20:af:7a!'
#
# Note: CAP_NET_RAW capability is required to use SOCK_RAW
import fcntl
import socket
import struct
@ThePredators
ThePredators / readme-mde.md
Last active June 20, 2025 02:53
Setup Mobile Development Environment

⭐ Setup Mobile Development Environment

⚠️ The following configuration has been tested on Intel, M1 & M2 Ships ⚠️

Pre-requisit :

If you have any issues with macOS, or need anything related to it check this documentation

Install Xcode Command Line tools :

@dcondrey
dcondrey / _xcode.sh
Last active June 26, 2024 19:58
(macOS Big Sur) Install Xcode from terminal, setup local development with Apache and PHP 8, and other configurations
# Install Command-line tools as dependency for Homebrew
xcode-select --install # Sets the development directory path to /Library/Developer/CommandLineTools
# Install Homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# Install Mas (command-line interface for Mac App Store)
brew install mas
# Search for Xcode showing only the first 5 results
mas search xcode | head -5
@tekin
tekin / .gitattributes
Last active July 2, 2025 17:00
An example .gitattributes file that will configure custom hunk header patterns for some common languages and file formats. See https://tekin.co.uk/2020/10/better-git-diff-output-for-ruby-python-elixir-and-more for more details.
# Stick this in your home directory and point your Global Git config at it by running:
#
# $ git config --global core.attributesfile ~/.gitattributes
#
# See https://tekin.co.uk/2020/10/better-git-diff-output-for-ruby-python-elixir-and-more for more details
*.c diff=cpp
*.h diff=cpp
*.c++ diff=cpp
*.h++ diff=cpp
@secretgspot
secretgspot / timelapse.sh
Created September 22, 2020 01:50 — forked from aemkei/timelapse.sh
Create a Timelapse with ffmpeg
ffmpeg -framerate 25 -f image2 -pattern_type glob -i "*.JPG" -s:v 1920x1440 -c:v libx264 -r 25 ../timelapse.mp4
// the donut code with fixed-point arithmetic; no sines, cosines, square roots, or anything.
// a1k0n 2020
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#define R(mul,shift,x,y) \
_=x; \
x -= mul*y>>shift; \
@madhums
madhums / react-native-ecosystem-reading.md
Created February 25, 2020 22:43
react native ecosystem reading

Basically you need to get familiar with the react ecosystem. Here's some that you would be widely using

  • React: Some important concepts here are
  • Redux: I am assuming you already know about this
  • Redux Saga: for async api comms
  • React Native: Pretty much uses the same react, redux stuff except for some new interfaces. Some important things to learn here are
@reegnz
reegnz / README.md
Last active June 8, 2025 03:33
Implementing a jq REPL with fzf

Implementing a jq REPL with fzf

Update: I created jq-zsh-plugin that does this.

One of my favourite tools of my trade is jq. It essentially enables you to process json streams with the same power that sed, awk and grep provide you with for editing line-based formats (csv, tsv, etc.).

Another one of my favourite tools is fzf.