Skip to content

Instantly share code, notes, and snippets.

View Nuclearfossil's full-sized avatar

Ash Matheson Nuclearfossil

View GitHub Profile
@Nuclearfossil
Nuclearfossil / starship_01.toml
Last active April 21, 2024 02:08
Some Starship gists I'm evaluating
# This Powerline style preset is a combination of few presets available in https://starship.rs
# and some other preset find on the web. I cannot recall from exactly where to give proper credit to the original authors.
# To add a unicode character, it must start with a \uCCCC, for example \uE0B6 creates the half circle nerd font character.
# Also, make sure you are using the correct font in your terminal program. There is a difference between Powerline and Nerd Font
# programs. Make sure you use Nerd Fonts.
# unicode references: https://en.wikipedia.org/wiki/List_of_Unicode_characters#Unicode_symbols
# https://www.nerdfonts.com/cheat-sheet
#add_newline = false
command_timeout = 10000
@Nuclearfossil
Nuclearfossil / gist:3ac61771bfc0d34d52561153b32d95b3
Last active March 21, 2023 02:14
Using cmake to build zlib ... and others!
Let's start with building zlib.
## First
You're going to want to set up a build structure for doing anything with cmake build systems.
Let's say you're keeping all your source projects on your D: drive. You'll want to have a build structure that looks like this:
D:
- dev // where I like to keep all my development projects
- git // where we get our git based projects
@Nuclearfossil
Nuclearfossil / Microsoft.Powershell_profile.ps1
Last active December 6, 2022 18:41
My current Powershell startup script
# To edit this file, in powershell type: `code $profile`
#
# If you need to remove/update PSReadline, you'll need to remove the module
# from your powershell modules folder. You'll need to close all powershell instances
# and delete the `PSReadline` module folder manuall before you install it with
# `Install-Module PSReadline`.
# after that, you should be good.
#
# To install starship on powershell, from the Admin command line, enter
# scoop install starship
@Nuclearfossil
Nuclearfossil / settings.json
Last active December 4, 2022 04:38
Windows Terminal settings
{
"$help": "https://aka.ms/terminal-documentation",
"$schema": "https://aka.ms/terminal-profiles-schema",
"actions":
[
{
"command": "paste",
"keys": "ctrl+v"
},
{
@Nuclearfossil
Nuclearfossil / gist:8812144da0f85885c6a6977f089f812f
Last active November 24, 2022 04:47
Powershell file locations
I'm putting together a little list of 'where to find stuff' for powershell.
Description Location
----------------------------------------------------- -------------------------------------------------------------------------------
Command history across all Powershells C:\Users\<name>\AppData\Roaming\Microsoft\Windows\PowerShell\PSReadLine\ConsoleHost_history.txt
Powershell system config (not shell config) $PSHOME\powershell.config.json
Powershell config file $PROFILE
C:\Users\<name>\Documents\PowerShell\Microsoft.PowerShell_profile.ps1
Edit Powershell config code $PROFILE
Reload Powershell config . $PROFILE
// cr3convert.cpp : This file contains the 'main' function. Program execution begins and ends there.
//
#include <iostream>
#include <unordered_map>
#include <vector>
#include <string>
#include <EDSDK.h>
#include "utils.h"
@Nuclearfossil
Nuclearfossil / emacs_cheatsheet.md
Last active May 14, 2019 13:41
Emacs Cheat Sheet

A simple cheatsheet for Emacs

Legend

  C- = Ctrl + additional key
  M- = Alt + additional key(s)

Pane commands

   Key        | Description
@Nuclearfossil
Nuclearfossil / metrics.fbs
Created January 13, 2016 01:30
Flatbuffers vs Protobuffers
namespace metrics;
enum Type : byte {
INT = 0,
DOUBLE,
STRING,
}
table Metric {
timestamp:ulong;
@Nuclearfossil
Nuclearfossil / HowToMergeAFork.md
Last active March 17, 2019 20:30
Git merge upstream process

How to merge an upstream into a fork, by example

Using my glfw branch (https://github.com/Nuclearfossil/glfw forked from https://github.com/glfw/glfw.git) as an example

Ensure that you have the correct upstream

You can use:

$ git remote show upstream
@Nuclearfossil
Nuclearfossil / StaticMeshSpawner.cpp
Created January 4, 2018 06:02
Spawning an existing Actor derived object (Unreal)
// Fill out your copyright notice in the Description page of Project Settings.
#include "StaticMeshSpawner.h"
#include "UObject/ConstructorHelpers.h"
#include "Engine/StaticMesh.h"
#include "Engine/CollisionProfile.h"
#include "Runtime/Engine/Classes/Components/InstancedStaticMeshComponent.h"
// Sets default values
AStaticMeshSpawner::AStaticMeshSpawner()