Skip to content

Instantly share code, notes, and snippets.

View kyzmitch's full-sized avatar

Andrei Ermoshin kyzmitch

  • Russia, Nizhny Novgorod
View GitHub Profile
@kyzmitch
kyzmitch / .zshrc
Created October 29, 2023 04:37
ZShell profile which sometimes needed instead of Bash (shorter than Bash profile)
PATH=$PATH:/opt/homebrew/Cellar/pyenv/2.3.30/bin
export PATH
JAVA_HOME=/opt/homebrew/Cellar/openjdk@17/17.0.8.1
export JAVA_HOME
# Get python from pyenv
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
@kyzmitch
kyzmitch / enum_with_raw_string.hpp
Created September 12, 2023 19:52
c++ meta programming example
#include <optional>
#include <string>
#include <type_traits>
/**
@tparam T must be an Enum type.
@tparam C converter must have `toString` and `fromString` static methods
*/
template<typename T,
typename C,
@kyzmitch
kyzmitch / reduce_xcode_build_process_number.txt
Last active September 12, 2023 19:54
Xcode workaround to limit too many build tasks
defaults write com.apple.dt.xcodebuild IDEBuildOperationMaxNumberOfConcurrentCompileTasks 6
defaults write com.apple.dt.xcodebuild PBXNumberOfParallelBuildSubtasks 6
defaults write com.apple.dt.Xcode PBXNumberOfParallelBuildSubtasks 6
defaults write com.apple.dt.Xcode IDEBuildOperationMaxNumberOfConcurrentCompileTasks 6
@kyzmitch
kyzmitch / swiftUI_menu_example.txt
Last active September 12, 2023 19:55
swiftUI menu example from web browser
//
// SiteMenuView.swift
// catowser
//
// Created by Andrei Ermoshin on 5/25/20.
// Copyright © 2020 andreiermoshin. All rights reserved.
//
#if canImport(SwiftUI)
import SwiftUI
@kyzmitch
kyzmitch / .bash_profile
Created February 22, 2019 12:03
Bash profile
alias ls="ls -la"
alias cd..="cd .."
alias cd...="cd ../.."
alias cd....="cd ../../.."
alias ..="cd .."
alias ...="cd ../.."
alias ....="cd ../../.."
export EDITOR=/usr/bin/vi