Skip to content

Instantly share code, notes, and snippets.

View necrose99's full-sized avatar

Michael L. necrose99

View GitHub Profile
@pdl
pdl / pl2py.pl
Created October 23, 2012 14:28
Convert perl scripts to python with the awesome power of regular expressions.
#!perl -w
=head1 NAME
pl2py.pl
=head1 DESCRIPTION
Attempts to convert perl scripts to python with the awesome power of regular expressions.
@terryoy
terryoy / gist:4435265
Last active April 7, 2022 22:33
My Gentoo Shell Command Collection
### emerge package management (need root access) ###
### "emerge" is a tool manipulating Gentoo's package management tool "Portage" ###
# update portage tree
emerge --sync
# search package
emerge --search pdf
emerge --searchdesc pdf
@666threesixes666
666threesixes666 / wallpaper
Created February 24, 2014 02:31
gentoo animated wallpaper
#!/bin/bash
DM=xfdesktop
WALLPAPER=/usr/lib64/misc/xscreensaver/cubicgrid
while ! [ $(pgrep -c $DM) = '1' ];do
sleep 1
done
$WALLPAPER -window-id $(xwininfo -name "Desktop" | grep 'Window id' | sed 's/.*\(0x[0-9a-z]*\).*/\1/g') &
@kozmonaut
kozmonaut / linux-packages
Created April 14, 2014 11:44
Backup and restore installed packages inside Linux Debian
# Backup your packages list
# Get a packages list
dpkg --get-selections > ~/Package.list
# Copy list of repositories
sudo cp /etc/apt/sources.list ~/sources.list
# Export repo keys
sudo apt-key exportall > ~/Repo.keys
# cat /etc/systemd/system/gitlab-sidekiq.service - for personal use
# cat /var/lib/systemd/system/gitlab-sidekiq.service - for package devs
#####################################################
#
# GitLab version : 5.x - 7.x
# Contributors : davispuh, mtorromeo, axilleas, boeserwolf91, Stefan Tatschner (rumpelsepp)
# Downloaded from : https://gitlab.com/gitlab-org/gitlab-recipes/tree/master/init/systemd
#
####################################################
# cat /etc/systemd/system/gitlab-unicorn.service - for personal use
# cat /var/lib/systemd/system/gitlab-unicorn.service - for package devs
#####################################################
#
# GitLab version : 5.x - 7.x
# Contributors : davispuh, mtorromeo, axilleas, boeserwolf91, Stefan Tatschner (rumpelsepp)
# Downloaded from : https://gitlab.com/gitlab-org/gitlab-recipes/tree/master/init/systemd
#
####################################################
@prurigro
prurigro / archroot.sh
Last active June 17, 2021 22:31
An overlayfs-based chroot management script for deployable arch build environments
#!/usr/bin/env bash
#
# archroot
# An overlayfs chroot management script for deployable arch build environments
#
# Version 1.18
#
# Written by Kevin MacMartin
# Released under the MIT license
@jirutka
jirutka / -README.md
Last active January 20, 2024 17:52
Use LDAP to manage system users on Gentoo Linux

Use LDAP to manage system users on Linux

This configuration uses nsswitch and compat mode, which is supposedly obsolete, but much more convenient than alternatives.

Install packages

emerge -va sys-auth/nss_ldap sys-auth/pam_ldap sys-apps/unscd

Note: unscd (Micro Name Service Caching Daemon) is not necessary, but it’s recommended.

@pcrockett
pcrockett / Sign.ps1
Last active May 3, 2023 19:10
PowerShell script to cryptographically sign assemblies that's easy to use with a Continuous Integration server
$script:SignToolPath = "C:\Program Files (x86)\Windows Kits\8.1\bin\x64\signtool.exe"
$script:TimestampServers = "http://timestamp.comodoca.com/authenticode",
"http://timestamp.verisign.com/scripts/timestamp.dll",
"http://timestamp.digicert.com"
$script:TimestampServerIndex = 0
$script:MaxRetries = 7
$ErrorActionPreference = "Stop"
Set-StrictMode -Version 3.0