Skip to content

Instantly share code, notes, and snippets.

View markthomas93's full-sized avatar
:shipit:
Working from home

Mark Thomas markthomas93

:shipit:
Working from home
  • freelance
  • California
View GitHub Profile
@seanstory
seanstory / demo_business_records.json
Last active June 9, 2022 21:58
A json listing of fake businesses
[
{
"business_id": "b72ed9bb-d74d-44f6-bb23-83ed7e51121d",
"business_name": "Jane",
"city": "New York",
"street_address": "100 W Houston St",
"phone_number": "(212) 254-7000",
"tags": [
"Breakfast & Brunch",
"American (New)",
const axios = require('axios').default;
axios.interceptors.request.use(x => {
const headers = {
...x.headers.common,
...x.headers[x.method],
...x.headers
};
//
// Deduplicated.swift
// CountriesSwiftUI
//
// Created by Alexey Naumov on 17.12.2019.
// Copyright © 2019 Alexey Naumov. All rights reserved.
//
import Foundation
import Combine
@O1ahmad
O1ahmad / crystal-disk-mark-fio-bench.sh
Created December 17, 2019 17:23
CrystalDiskMark-esque Disk Benchmark (using fio)
#!/bin/bash
LOOPS=5 #How many times to run each test
SIZE=1024 #Size of each test, multiples of 32 recommended for Q32 tests to give the most accurate results.
WRITEZERO=0 #Set whether to write zeroes or randoms to testfile (random is the default for both fio and crystaldiskmark); dd benchmarks typically only write zeroes which is why there can be a speed difference.
QSIZE=$(($SIZE / 32)) #Size of Q32Seq tests
SIZE+=m
QSIZE+=m
@dotproto
dotproto / LICENSE
Created November 15, 2019 21:21
Minimal working Manifest V3 extension.
Copyright 2019 Google LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
# Luke's config for the Zoomer Shell
# Enable colors and change prompt:
autoload -U colors && colors
PS1="%B%{$fg[red]%}[%{$fg[yellow]%}%n%{$fg[green]%}@%{$fg[blue]%}%M %{$fg[magenta]%}%~%{$fg[red]%}]%{$reset_color%}$%b "
# History in cache directory:
HISTSIZE=10000
SAVEHIST=10000
HISTFILE=~/.cache/zsh/history
@tomtastic
tomtastic / smb.conf
Last active January 27, 2025 13:27
Samba 4.13.5 config for MacOS Monterey
#
# Sample configuration file for the Samba suite for Debian GNU/Linux.
#
#
# This is the main Samba configuration file. You should read the
# smb.conf(5) manual page in order to understand the options listed
# here. Samba has a huge number of configurable options most of which
# are not shown in this example
#
# Some options that are often worth tuning have been included as
@tuanpt98
tuanpt98 / speed-test.sh
Created August 6, 2019 10:53
Test OS and Disk Information
#!/bin/bash
#######################################################
# Tocdo.net Linux Server Benchmarks v1.5
# Run speed test:
# curl -Lso- tocdo.net | bash
#######################################################
# Colors
RED='\033[0;31m'
GREEN='\033[0;32m'
@markthomas93
markthomas93 / Batch File Rename.scpt
Created July 8, 2019 22:44 — forked from oliveratgithub/Batch File Rename.scpt
Simple AppleScript to easily batch rename multiple files sequentially. GUI asks user to select files and input a name before renaming.
-- This code comes from https://gist.github.com/oliveratgithub/
-- Open in AppleScript Editor and save as Application
-- ------------------------------------------------------------
--this is required to break the filename into pieces (separate name and extension)
set text item delimiters to "."
tell application "Finder"
set all_files to every item of (choose file with prompt "Choose the Files you'd like to rename:" with multiple selections allowed) as list
display dialog "New file name:" default answer ""
set new_name to text returned of result
--now we start looping through all selected files. 'index' is our counter that we initially set to 1 and then count up with every file.