Skip to content

Instantly share code, notes, and snippets.

View MaximBazarov's full-sized avatar
💤
ZEN

Maxim Bazarov MaximBazarov

💤
ZEN
View GitHub Profile
@MaximBazarov
MaximBazarov / xed_xcode_invocation_tool.md
Created July 27, 2023 15:23 — forked from dive/xed_xcode_invocation_tool.md
Xcode invocation tool - xed

Xcode invocation tool - xed

xed is a command-line tool that launches the Xcode application and opens the given documents (xcodeproj, xcworkspace, etc.), or opens a new document, optionally with the contents of standard input.

If you work from the command line, this tool is a better option than open (which can open Xcode projects as well). Why?

  • xed knows about the current selected Xcode version (open behaves unpredictably if you have multiple Xcode installed)
  • You can use it open all files from a specific commit (with a little help explained below). It is useful on code-reviews or when you want to explore significant changes in the repository
  • You can use it as a "quick open" helper. Helps with monorepo phenomena, when you have hundreds of projects in the repository (I will show you an example below)
@MaximBazarov
MaximBazarov / bouncywin.swift
Created December 7, 2019 15:22 — forked from ihnorton/bouncywin.swift
Bouncy window manager "solution"
import Cocoa
import Foundation
import AppKit
import CoreFoundation
import ApplicationServices
/// https://jvns.ca/blog/2019/11/25/challenge--make-a-bouncy-window-manager/
/*
This code runs the following sequence:
// Safely Modifying The View State (SwiftUI)
// https://swiftui-lab.com
// https://swiftui-lab.com/state-changes
import SwiftUI
struct CustomView: View {
var body: some View {
NavigationView {
@MaximBazarov
MaximBazarov / .inputrc
Last active April 1, 2019 20:02 — forked from timf/.inputrc
~/.inputrc for OSX up and down arrow bash history completion (enter the beginning of a command and press up to scroll through matches)
set completion-ignore-case On
"\e[B": history-search-forward
"\e[A": history-search-backward