Skip to content

Instantly share code, notes, and snippets.

@TomyLobo
TomyLobo / README.md
Last active November 4, 2023 14:59
How to disable Cortana
  1. Save disable-cortana.reg as UTF-16 little endian with BOM or UCS-2 little endian with BOM
    • Windows' Notepad calls that "Unicode"
  2. Double-click it and confirm any prompts
  3. Reboot Windows

To verify that it worked, open the start menu and type anything. Search should be limited to local results only and not blast all your keystrokes into the net.

Source: https://pureinfotech.com/disable-web-search-windows-10-version-1803/

@TomyLobo
TomyLobo / scan-scsi-hosts.sh
Created January 16, 2018 10:08
How to scan all SCSI hosts
for host in /sys/class/scsi_host/*; do echo "- - -" > "$host"/scan; done
@TomyLobo
TomyLobo / InstallingMeld.md
Last active July 2, 2021 13:06 — forked from kjlubick/InstallingMeld
How to install Meld on Windows and getting it set up with Git

After installing it https://download.gnome.org/binaries/win32/meld/ I had to tell Git to use Meld:

git config --global merge.tool meld
git config --global diff.tool meld

The last command tells Git where it can find Meld and depends on whether you are using Cygwin or Git for Windows:

Git for Windows:

@TomyLobo
TomyLobo / build.sh
Last active February 8, 2017 13:18
Script to build tcl/tk on Cygwin without requiring an X server at runtime
#!/bin/bash
# This script downloads and builds tcl/tk and runs a small test case with it to verify that it works without an X server.
# It was tested with 8.6.6 and 8.5.18.
# At its core it's just "cd unix && ./configure --enable-threads --enable-64bit && make"
# I recommend to run this in a separate directory.
#
# Usage: ./build.sh [<version>]
#
# version - The tcl/tk version to use, defaults to 8.6.6.
"GameUI_vote_failed" "Vote Failed."
"GameUI_vote_failed_quorum" "Not enough players voted."
"GameUI_vote_failed_yesno" "Yes votes must exceed No votes."
"GameUI_vote_failed_vote_spam" "You called a vote recently and can not call another for %s1 seconds."
"GameUI_vote_failed_transition_vote" "You cannot call a new vote while other players are still loading."
"GameUI_vote_failed_disabled_issue" "Server has disabled that issue."
"GameUI_vote_failed_map_not_found" "That map does not exist."
"GameUI_vote_failed_map_not_valid" "That map was not found in the server's map cycle."
"GameUI_vote_failed_map_name_required" "You must specify a map name."
"GameUI_vote_failed_recently" "This vote failed recently and can not be called again for %s1 seconds."
@TomyLobo
TomyLobo / functions.lua
Last active May 28, 2016 09:27
HLSW Lua function list
Created using the following code:
local walked = {}
local function rec(prefix, tbl)
if prefix == "package.loaded." or walked[tbl] then return end
walked[tbl] = true
for k, v in pairs(tbl) do
Debug.Print(prefix..k)
if type(v) == 'table' then
rec(prefix..k..'.', v)
end
@TomyLobo
TomyLobo / fix-debian-bug-573482.sh
Last active April 20, 2016 08:23
Workaround for Debian bug #573482
#!/bin/bash
set -e
fixjar=aaafix-debian-bug-573482.jar
pom_xml=org/apache/maven/project/pom-4.0.0.xml
first_component="${pom_xml%%/*}"
cd /usr/share/maven2/lib
@TomyLobo
TomyLobo / functions.lua
Last active December 28, 2015 23:01
Function list for Starbound Server Beta v. Glad Giraffe - Update 3' Revision: 30555b17a491c2a97ab0afbff3b848a1fd937dbd
{
xpcall: <function reg:8>,
jresize: <function reg:8>,
table: {
pack: <function reg:9>,
unpack: <function reg:9>,
sort: <function reg:9>,
concat: <function reg:9>,
move: <function reg:9>,
@TomyLobo
TomyLobo / Gemfile
Last active October 6, 2015 11:56
Puppet catalog to TGF graph format converter
source 'https://rubygems.org'
gem 'tgf', '~> 1.1.0'
@TomyLobo
TomyLobo / patrolturtle.lua
Last active October 4, 2015 13:37
ComputerCraft turtle to patrol a rectangular area delimited by obsidian blocks
shell.run('clear')
print("Please put obsidian in Slot 1 and mark the corners with obsidian.")
print("Go clockwise? (y/N)")
local clockwise = io.read():upper() == "Y"
local obsidian = 1
print("Going "..(clockwise and "clockwise" or "counter-clockwise")..".")
while true do
turtle.select(obsidian)