Step 1
Download macOS Installer (InstallAssistant.pkg). Here is the link to Sonoma beta installer:
| use objc::{msg_send, sel, sel_impl}; | |
| use rand::{distributions::Alphanumeric, Rng}; | |
| use tauri::{ | |
| plugin::{Builder, TauriPlugin}, | |
| Manager, Runtime, Window, | |
| }; // 0.8 | |
| const WINDOW_CONTROL_PAD_X: f64 = 15.0; | |
| const WINDOW_CONTROL_PAD_Y: f64 = 23.0; |
| class TimeElapsed: CustomStringConvertible { | |
| private let startTime: CFAbsoluteTime | |
| private var endTime: CFAbsoluteTime? | |
| init() { | |
| startTime = CFAbsoluteTimeGetCurrent() | |
| } | |
| var description: String { | |
| time |
| { | |
| "$schema": "https://zed.dev/schema/themes/v0.1.0.json", | |
| "name": "Vesper", | |
| "author": "Rauno Freiberg", | |
| "themes": [ | |
| { | |
| "name": "Vesper", | |
| "appearance": "dark", | |
| "style": { | |
| "border": "#101010", |
Step 1
Download macOS Installer (InstallAssistant.pkg). Here is the link to Sonoma beta installer:
| // | |
| // MultiPartFormData.swift | |
| // | |
| import Foundation | |
| /* Example Call site: */ | |
| func upload(imageData: Data) async throws { | |
| guard let url = URL(string: "https://example.com/upload") else { return } | |
| var multipartFormData = MultipartFormData() |
| /** | |
| * TypeScript currently lacks a way of typing a record of keys only but not values. | |
| * we need this because we want an object of typed keys but we want to leave the values inferred. | |
| * thankfully, we can do this with generics. This function allows the second generic's values to be inferred | |
| * so that our object is fully type safe for hugely complex types, but we can guarantee that all the keys we need exist. | |
| * It's not perfect, but it gets the job done for the time being | |
| */ | |
| export function ensureKeys<T>() { | |
| /** | |
| * Function that returns the value that gets put in, values are type-safely inferred |
Example of an automated script that does most of this: https://github.com/surpher/PactSwiftMockServer/blob/fb8148866bb05f49a0b1dcaae66c67bad1e7eca7/Support/build_rust_dependencies
curl https://sh.rustup.rs -sSf | sh| // Thanks to mminer on GitHub | |
| // https://gist.github.com/mminer/caec00d2165362ff65e9f1f728cecae2 | |
| import Cocoa | |
| class PreferencesViewController: NSTabViewController { | |
| private lazy var tabViewSizes: [NSTabViewItem: NSSize] = [:] | |
| private var lastSelectedTabViewItem: NSTabViewItem? = nil | |
| import Combine | |
| final class Keyboard: ObservableObject { | |
| // MARK: - Published Properties | |
| @Published var state: Keyboard.State = .default | |
| // MARK: - Private Properties |