hop
Hop: a small native macOS launcher. Clipboard history, find, on-device dictation and your coding agent behind one key.
Brought by drakestapleton
hop / Sources / FactoryMetrics.swift
| 1 | import Foundation |
| 2 | |
| 3 | /// Process-local measurements only. No timers, telemetry upload or user content. |
| 4 | @MainActor |
| 5 | enum FactoryMetrics { |
| 6 | private static var start: UInt64 = 0 |
| 7 | private static var recorded = false |
| 8 | static func begin() { start = DispatchTime.now().uptimeNanoseconds } |
| 9 | static func firstFreshSnapshot() { |
| 10 | guard !recorded, start != 0 else { return } |
| 11 | recorded = true |
| 12 | let elapsed = DispatchTime.now().uptimeNanoseconds - start |
| 13 | print("HOP_FACTORY first_fresh_snapshot_ns=\(elapsed)") |
| 14 | } |
| 15 | } |