Skip to content

Instantly share code, notes, and snippets.

@JunielKatarn
JunielKatarn / ActivateProject64.cs
Created February 28, 2022 04:37
Activator for the Project64 Emulator
using ICSharpCode.SharpZipLib.Zip.Compression.Streams;
using Microsoft.Win32;
using System.Security.Cryptography;
using System.Text;
class Program
{
static void Main()
{
var regBytes = (byte[])Registry.GetValue(@"HKEY_CURRENT_USER\Software\Project64", "user", null)!;
@JunielKatarn
JunielKatarn / php.ini
Last active August 9, 2018 07:11
Minimal PHP configuration for XDebug and SQLite
[PHP]
extension_dir = "ext"
zend_extension=php_xdebug-2.5.5-7.1-vc14-x86_64.dll
;XDebug
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_port=9000
xdebug.idekey=netbeans-xdebug
Param (
[String]
$Path = (ls $env:USERPROFILE\AppData\Local\Jammit | ? { $_.Attributes -eq 'Directory' })[0].FullName
)
foreach ($dir in (ls $Path))
{
if (! (Test-Path $Path\$dir\info.plist)) {
continue
}
@JunielKatarn
JunielKatarn / xdebug.ini
Last active October 19, 2016 11:07
INI file to make XDebug work with NetBeans on Ubuntu 16.04 and Mac OS 10.11.
zend_extension=xdebug.so
xdebug.show_error_trace=1
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000 # For OS X, use 9001
xdebug.idekey=netbeans-xdebug
xdebug.remote_log="/tmp/xdebug.log"
@JunielKatarn
JunielKatarn / mergeswm.ps1
Last active May 4, 2023 08:53
Correct way to merge SWM files into a WIM file. TechNet documentation is wrong for this command.
# Taken from https://technet.microsoft.com/en-us/library/hh825258.aspx
Param
(
$ImageName
)
dism /Export-Image `
/SourceImageFile:${ImageName}.swm `
/SWMFile:${ImageName}*.swm `
/SourceIndex:1 `
@JunielKatarn
JunielKatarn / settings.json
Last active October 28, 2016 07:52
Visual Studio Code user settings
// Place your settings in this file to overwrite the default settings
{
"editor.insertSpaces": false,
"editor.renderWhitespace": "all",
"files.encoding": "utf8",
"files.eol": "\n"
}
@JunielKatarn
JunielKatarn / DummyAudioPlugin.cpp
Created July 19, 2016 03:42
Pass-through audio plugin implementation for Project64.
#include <stdint.h>
#include <Windows.h>
#define EXPORT __declspec(dllexport)
#define CALL __cdecl
typedef struct {
uint16_t Version;
uint16_t Type;
char Name[100];
@JunielKatarn
JunielKatarn / xstartup
Created May 7, 2016 23:18
Fix gray screen on Ubuntu VNC (14.04+). Taken from http://onkea.com/ubuntu-vnc-grey-screen/
#!/bin/sh
def
export XKL_XMODMAP_DISABLE=1
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
gnome-panel &
gnome-settings-daemon &
metacity &
nautilus &
@JunielKatarn
JunielKatarn / nbpython\nbbuild\user.build.properties
Last active April 30, 2016 06:22
Local .properties file to build NetBeans/Python
cluster.config=python
permit.jdk8.builds=true
build.compiler=extJavac
java.compilerargs=-J-Xmx2G
netbeans.full.hack=true
nbjdk.home=/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home
#nbjdk.home=C:\\Program Files\\Java\\jdk8
#test.user.dir=C:\\Path\\To\\testuserdir.win
@JunielKatarn
JunielKatarn / vsDiffMerge.gitconfig
Last active March 29, 2024 00:03
Git config to use vsdiffmerge.exe as a diff/merge tool
# PLEASE SEE FEEDBACK. This script is not up to date and may not use the best practices.
[diff]
tool = vsdiffmerge
[difftool]
prompt = false
[difftool "vsdiffmerge"]
cmd = '"C:/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/IDE/vsdiffmerge.exe"' "$LOCAL" "$REMOTE" //t
keepbackup = false
trustexitcode = true