Skip to content

Instantly share code, notes, and snippets.

View RickeyWard's full-sized avatar

DiamondDrake RickeyWard

  • DiamondDrake Software and Design, @SwampfoxInc
  • Columbia, SC
View GitHub Profile
@webarchitect609
webarchitect609 / terminal.sh
Last active November 7, 2025 19:14
Git: disable GPG signing for current repo only.
# Write local
git config --local commit.gpgsign false
# Read local (if never set, can be an empty value)
git config --local commit.gpgsign
@PierBover
PierBover / client.js
Created October 1, 2018 23:28
Node.js UDP Broadcast example
const dgram = require('dgram');
const message = new Buffer('Server?');
const socket = dgram.createSocket('udp4');
socket.on('listening', function () {
socket.setBroadcast(true);
setInterval(() => {
socket.send(message, 0, message.length, 5555, '255.255.255.255');
}, 5000);
});
@gdellicarpini
gdellicarpini / aliases_centos.md
Last active July 21, 2024 22:28
Add permanent aliases in Linux CentOS

Aliases for all users

  • Create a file in /etc/profile.d/ directory

      - myAlias.sh
    
  • Define the alias in the file

      alias gotoserver1="ssh [email protected]"
    
@gboudreau
gboudreau / AuthyToOtherAuthenticator.md
Last active December 2, 2025 19:07 — forked from Ingramz/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Exporting your 2FA tokens from Authy to transfer them into another 2FA application

IMPORTANT - Update regarding deprecation of Authy desktop apps

Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.

And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export your tokens.

If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.

@adamkearsley
adamkearsley / tabs.service.ts
Created February 9, 2017 13:09 — forked from 0x1ad2/tabs.service.ts
A service to hide and show tabs in Ionic 2
import {Injectable} from '@angular/core';
// Declare TabsService as a provider in app.module.ts
// Inject TabsService in your class: constructor(public tabs: TabsService){}
// Use the this.tabs.hide() or this.tabs.show() methods wherever you want
@Injectable()
export class TabsService {
constructor() {}
public hide() {
# output all the colour combinations for text/background
# https://stackoverflow.com/questions/20541456/list-of-all-colors-available-for-powershell/41954792#41954792
$colors = [enum]::GetValues([System.ConsoleColor])
Foreach ($bgcolor in $colors){
Foreach ($fgcolor in $colors) { Write-Host "$fgcolor|" -ForegroundColor $fgcolor -BackgroundColor $bgcolor -NoNewLine }
Write-Host " on $bgcolor"
}
import { Directive } from '@angular/core';
import { ViewController } from 'ionic-angular';
@Directive({
selector: '[hideTabs]'
})
export class HideTabsDirective {
constructor(private viewCtrl: ViewController) {
// hide tabs when view loads
@DanielSWolf
DanielSWolf / Program.cs
Last active November 9, 2025 21:44
Console progress bar. Code is under the MIT License: http://opensource.org/licenses/MIT
using System;
using System.Threading;
static class Program {
static void Main() {
Console.Write("Performing some task... ");
using (var progress = new ProgressBar()) {
for (int i = 0; i <= 100; i++) {
progress.Report((double) i / 100);
@tsiege
tsiege / The Technical Interview Cheat Sheet.md
Last active December 5, 2025 18:04
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

ANNOUNCEMENT

I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!






\

@wohali
wohali / simple-view-no-null.erl
Created February 24, 2014 06:39
Simple Erlang views for CouchDB
%% this is an exact match for the original JS function
fun({Doc}) ->
case proplists:is_defined(<<"diet">>, Doc) of
true ->
Emit(proplists:get_value(<<"diet">>, Doc), 1);
false ->
ok
end
end.