Skip to content

Instantly share code, notes, and snippets.

View rogeruiz's full-sized avatar
⌨️
https://rogerisworking.tumblr.com

Roger Steve Ruiz rogeruiz

⌨️
https://rogerisworking.tumblr.com
View GitHub Profile
@rogeruiz
rogeruiz / XDG.cheat-sheet.md
Created February 24, 2024 00:34 — forked from roalcantara/XDG.cheat-sheet.md
XDG cheat sheet
View XDG.cheat-sheet.md

XDG - Base Directory Specification

Directories

Base

The intended use-case for BaseDirectories is to query the paths of user-invisible standard directories that have been defined according to the conventions of the operating system the library is running on.

@rogeruiz
rogeruiz / customSelect.js
Created March 11, 2014 17:42
Custom Select AMD Module
View customSelect.js
define(function (require) {
var $ = require('jquery');
var $el = $('.js-custom-select');
var numEl = $el.length;
// Check if module should run.
if (!numEl) { return false; }
// Proceed with module execution
if ($el.data('map')) {
@rogeruiz
rogeruiz / randuh.js
Last active December 14, 2023 00:41
Now for something completely random
View randuh.js
const MAX = 39;
const MIN = 33;
const COUNT = 200;
const nn = new Array(COUNT).fill();
/**
* @param {any[]} a - An array to be used to create a new array of random
* values. The contents of the array is not modified.
* @returns {number[]} - An array of the same length passed in with random
* numbers at each index
@rogeruiz
rogeruiz / gruvbox-material-alacritty.yml
Created September 19, 2023 13:05 — forked from ttys3/gruvbox-material-alacritty.yml
Gruvbox Material for Alacritty
View gruvbox-material-alacritty.yml
# The definition of color schemes.
schemes:
gruvbox_material_hard_dark: &gruvbox_material_hard_dark
primary:
background: '0x1d2021'
foreground: '0xd4be98'
normal:
black: '0x32302f'
red: '0xea6962'
green: '0xa9b665'
@rogeruiz
rogeruiz / README.md
Last active September 18, 2023 20:36
MB-12251 Prime Actions using HTTPie (https://httpie.io)
View README.md

MB-12251 Prime Action to validate

Using this set of scripts, run the get-exp-certs-out-of-chamber.sh first. Run this file from inside of the transcom/mymove repo. Then after that, open the request-payload.json file and edit the moveTaskOrderID to match a GUID for a Move that the Prime will create an MTO shipment for. After saving request-payload.json, run the create-mto-shipment-as-prime.sh to modify the Move. You should see a 200 response in the terminal.

Running the scripts

All scripts are run by calling bash first before typing the path to the script. Do not run this script within the transcom/mymove repository as it will download certificates into your repository.

@rogeruiz
rogeruiz / macos-tmux-256color.md
Created April 21, 2023 20:11 — forked from bbqtd/macos-tmux-256color.md
Installing tmux-256color for macOS
View macos-tmux-256color.md

Installing tmux-256color for macOS

  • macOS 10.15.5
  • tmux 3.1b

macOS has ncurses version 5.7 which does not ship the terminfo description for tmux. There're two ways that can help you to solve this problem.

The Fast Blazing Solution

Instead of tmux-256color, use screen-256color which comes with system. Place this command into ~/.tmux.conf or ~/.config/tmux/tmux.conf(for version 3.1 and later):

@rogeruiz
rogeruiz / readme.md
Created January 22, 2023 23:03 — forked from eddiewebb/readme.md
Hugo JS Searching with Fuse.js
@rogeruiz
rogeruiz / dms_nonmasteruser.sql
Last active October 7, 2022 19:07
AWS DMS NonMasterUser documentation revisted
View dms_nonmasteruser.sql
-- ███████╗██████╗ ██████╗ ███╗ ███╗ ████████╗██╗ ██╗███████╗
-- ██╔════╝██╔══██╗██╔═══██╗████╗ ████║ ╚══██╔══╝██║ ██║██╔════╝
-- █████╗ ██████╔╝██║ ██║██╔████╔██║ ██║ ███████║█████╗
-- ██╔══╝ ██╔══██╗██║ ██║██║╚██╔╝██║ ██║ ██╔══██║██╔══╝
-- ██║ ██║ ██║╚██████╔╝██║ ╚═╝ ██║ ██║ ██║ ██║███████╗
-- ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝╚══════╝
--
-- ██████╗ ███████╗███████╗██╗ ██████╗██╗ █████╗ ██╗ █████╗ ██╗ ██╗███████╗
-- ██╔═══██╗██╔════╝██╔════╝██║██╔════╝██║██╔══██╗██║ ██╔══██╗██║ ██║██╔════╝
-- ██║ ██║█████╗ █████╗ ██║██║ ██║███████║██║ ███████║██║ █╗ ██║███████╗
@rogeruiz
rogeruiz / jquery.infiniteCarousel.coffee
Created September 17, 2012 18:28
Basic Infinite Carousel jQuery Plugin in CoffeeScript
View jquery.infiniteCarousel.coffee
# Infinite Carousel Plugin
do ($ = jQuery, window = window) ->
pluginName = 'infiniteCarousel'
document = window.document
defaults =
onInit: ->
onNext: ->
onPrev: ->
View create_markdown_from_cards.py
import wikipedia
from bs4 import BeautifulSoup, Tag
import datetime
import urllib.parse
from ankisync2.apkg import Apkg
from ankisync2.anki20 import db
if __name__ == "__main__":