Skip to content

Instantly share code, notes, and snippets.

View musm's full-sized avatar

Mustafa Mohamad musm

View GitHub Profile
@alanorth
alanorth / pre-process-media.sh
Last active February 23, 2024 16:24
Script for preparing media files for long-term archival
#!/usr/bin/env bash
#
# pre-process-media.sh v2021-12-26
#
# Prepare a directory of images and videos for long-term archival by normalizing
# their names, optimizing JPEGs with jpeg-archive, and stripping embedded MP4s
# from Android Motion Photos.
#
# SPDX-License-Identifier: GPL-3.0-only
@JerryLokjianming
JerryLokjianming / Crack Sublime Text Windows and Linux.md
Last active April 25, 2024 04:03
Crack Sublime Text 3.2.2 Build 3211 and Sublime Text 4 Alpha 4098 with Hex

How to Crack Sublime Text 3.2.2 Build 3211 with Hex Editor (Windows | Without License) ↓

  1. Download & Install Sublime Text 3.2.2 Build 3211
  2. Visit https://hexed.it/
  3. Open file select sublime_text.exe
  4. Offset 0x8545: Original 84 -> 85
  5. Offset 0x08FF19: Original 75 -> EB
  6. Offset 0x1932C7: Original 75 -> 74 (remove UNREGISTERED in title bar, so no need to use a license)
@nickbudi
nickbudi / README.md
Last active November 4, 2023 10:53
Cygwin git compatibility with VS Code (or other Windows programs) using cygpath

Cygwin Git + VS Code compatibility

Thanks and credit to mattn and ferreus on GitHub.

Also check out Developing on WSL and/or wslpath (Windows 10 Build 17046 or later) if you're using the Windows Subsystem for Linux.

@ZacLN
ZacLN / pkgdeps.jl
Created July 29, 2017 10:32
Find package dependencies
function pkgdeps(pkg::String, metadir = "/home/zac/.julia/v0.6/METADATA")
deps = []
for pdir in readdir(metadir)
if isdir(joinpath(metadir,pdir)) && "versions" in readdir(joinpath(metadir,pdir))
for ver in readdir(joinpath(metadir, pdir, "versions"))
if isfile(joinpath(metadir, pdir, "versions",ver,"requires"))
reqs = readlines(joinpath(metadir, pdir, "versions",ver,"requires"))
for r in reqs
if first(split(r, " ")) == pkg
push!(deps, (pdir, ver))
@max-mapper
max-mapper / bibtex.png
Last active March 10, 2024 21:53
How to make a scientific looking PDF from markdown (with bibliography)
bibtex.png
#!/usr/bin/env julia
# inspired by http://stackoverflow.com/questions/40031913/simulate-a-bouncing-ball
# and the inspired Chris Rackauckas
using DifferentialEquations, ParameterizedFunctions, NLsolve, Luxor
f = @ode_def BallBounce begin
dy = v
dv = -g
@mkborregaard
mkborregaard / DepsPlot.jl
Created March 2, 2017 20:49
A Plots recipe for the dependency structure of julia packages
type MyGraph
source::AbstractVector{Int}
destiny::AbstractVector{Int}
end
type DepsGraph
g::MyGraph
d::Int
names::Vector{String}
end
@iambkramer
iambkramer / Export-Chocolatey.ps1
Last active July 17, 2020 19:54 — forked from alimbada/Export-Chocolatey.ps1
Export installed Chocolatey packages as chocolatey script
choco list -lo -r -y | % { $_.Split('|') | select -First 1 } | % { "choco install " + $_ + " -y" }
choco list -lo -r -y | % { $_.Split('|') | select -First 1 } | % { "choco install " + $_ + " -y" } | Out-file choco-software.txt
@mlocati
mlocati / main.c
Last active January 19, 2024 14:10
Enable/disable/check color support for Windows (ENABLE_VIRTUAL_TERMINAL_PROCESSING flag)
#define _WIN32_WINNT 0x0600
#include <stdio.h>
#include <windows.h>
#include <fileapi.h>
#ifndef ENABLE_VIRTUAL_TERMINAL_PROCESSING
#define ENABLE_VIRTUAL_TERMINAL_PROCESSING 0x0004
#endif