Skip to content

Instantly share code, notes, and snippets.

View julyfun's full-sized avatar
🐷
working

Junjie Fang julyfun

🐷
working
  • Shanghai Jiao Tong University
  • Shanghai, China
  • 18:10 (UTC +08:00)
View GitHub Profile
@julyfun
julyfun / .clang-format
Created July 30, 2024 07:03
rust-like clang format (rustfmt)
AccessModifierOffset: -4
AlignAfterOpenBracket: BlockIndent
AlignConsecutiveMacros: false
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: DontAlign
AlignOperands: false
AlignTrailingComments: false
AllowAllArgumentsOnNextLine: false
AllowAllConstructorInitializersOnNextLine: false
@Jomy10
Jomy10 / tagged_union.h
Last active January 11, 2025 06:44
C Tagged Union Macro
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
// Author: Jonas Everaert
//
// You can change these however you like
#define _TU_TYPE_PREFIX(Type) T_##Type
@YodaEmbedding
YodaEmbedding / .clang-format
Last active April 27, 2025 20:19
.clang-format for Rust style (rustfmt)
AccessModifierOffset: -2
AlignAfterOpenBracket: BlockIndent # New in v14. For earlier clang-format versions, use AlwaysBreak instead.
AlignConsecutiveMacros: false
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: DontAlign
AlignOperands: false
AlignTrailingComments: false
AllowAllArgumentsOnNextLine: false
AllowAllConstructorInitializersOnNextLine: false
@tsl0922
tsl0922 / .tmux.conf
Last active March 24, 2025 02:15
vim style tmux config
# vim style tmux config
# use C-a, since it's on the home row and easier to hit than C-b
set-option -g prefix C-a
unbind-key C-a
bind-key C-a send-prefix
set -g base-index 1
# Easy config reload
bind-key R source-file ~/.tmux.conf \; display-message "tmux.conf reloaded."