apt-get install neovim vim tmux htop git python3-pip curl
mkdir -p /opt/local/dev
cd /opt/local/dev
git clone https://github.com/imartinez/privateGPT
cd privateGPT
mkdir models
cd models
curl -kLO https://gpt4all.io/models/ggml-gpt4all-j-v1.3-groovy.bin
cd ..
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//#!/usr/bin/swift | |
import Foundation | |
import QuartzCore | |
//let task = Process() | |
//task.launchPath = "/usr/bin/defaults" | |
//task.arguments = ["write","com.apple.dock","persistent-apps","-array-add","{\"tile-type\"=\"spacer-tile\";}"] | |
//let pipe = Pipe() | |
//task.standardOutput = pipe | |
//task.standardError = pipe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Created by Pedro Rojas (aka Pitt) | |
// Link to learn more about this code: https://youtu.be/kZ7JPFUVv1w | |
import SwiftUI | |
import WebKit | |
@resultBuilder | |
struct HtmlBuilder { | |
static func buildBlock() -> [HtmlTag] { | |
[] |
Configuring the VM in Joyent SmartOS /opt/local/artifacts/sn01bhyveUbuntuFM20S01.json had the following content
VCPUs in my case for this install: https://www.intel.com/content/www/us/en/products/sku/123550/intel-xeon-silver-4114-processor-13-75m-cache-2-20-ghz/specifications.html, meaning depending on the software to install one can pick anything between 1 and 10 for "vcpus"
{
"autoboot": false,
"brand": "bhyve",
"alias": "sn01bhyveUbuntuFM20S01",
"hostname": "sn01bhyveUbuntuFM20S01",
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
import PhotosUI | |
class ViewController: UIViewController { | |
@IBAction func presentPickerForImagesIncludingLivePhotos(_ sender: Any ) { | |
presentPicker( filter: PHPickerFilter.images ) | |
} | |
private func presentPicker( filter: PHPickerFilter ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.http.server.configuration.address = .unixDomainSocket( path: "/var/run/tld.domain.login" ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
// Model. | |
struct Employee: Codable { | |
let id: Int | |
let name: String | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ exa -T $(pwd) | |
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Templates | |
├── File Templates | |
│ ├── iOS | |
│ │ ├── Apple Watch | |
│ │ │ └── WatchKit Settings Bundle.xctemplate | |
│ │ │ ├── ___FILEBASENAME___.bundle | |
│ │ │ │ ├── en.lproj | |
│ │ │ │ │ └── Root.strings | |
│ │ │ │ └── Root.plist |