1
0
mirror of https://github.com/nicoverbruggen/phpmon.git synced 2025-08-07 20:10:08 +02:00

♻️ phpmon -> PHP Monitor

This commit is contained in:
2019-07-15 17:14:09 +02:00
parent 0fc7f2c905
commit 4ba3415bf4
19 changed files with 38 additions and 53 deletions

2
.gitignore vendored
View File

@ -1,2 +1,4 @@
phpmon.xcodeproj/project.xcworkspace phpmon.xcodeproj/project.xcworkspace
phpmon.xcodeproj/xcuserdata phpmon.xcodeproj/xcuserdata
PHP Monitor.xcodeproj/project.xcworkspace
PHP Monitor.xcodeproj/xcuserdata

View File

@ -21,11 +21,10 @@
C4D8016622B1584700C6DA1B /* Startup.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4D8016522B1584700C6DA1B /* Startup.swift */; }; C4D8016622B1584700C6DA1B /* Startup.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4D8016522B1584700C6DA1B /* Startup.swift */; };
C4EE188422D3386B00E126E5 /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4EE188322D3386B00E126E5 /* Constants.swift */; }; C4EE188422D3386B00E126E5 /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4EE188322D3386B00E126E5 /* Constants.swift */; };
C4F8C0A422D4F12C002EFE61 /* DateExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4F8C0A322D4F12C002EFE61 /* DateExtension.swift */; }; C4F8C0A422D4F12C002EFE61 /* DateExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4F8C0A322D4F12C002EFE61 /* DateExtension.swift */; };
C4F8C0A622D4FA41002EFE61 /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = C4F8C0A522D4FA41002EFE61 /* README.md */; };
/* End PBXBuildFile section */ /* End PBXBuildFile section */
/* Begin PBXFileReference section */ /* Begin PBXFileReference section */
C41C1B3322B0097F00E7CF16 /* phpmon.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = phpmon.app; sourceTree = BUILT_PRODUCTS_DIR; }; C41C1B3322B0097F00E7CF16 /* PHP Monitor.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "PHP Monitor.app"; sourceTree = BUILT_PRODUCTS_DIR; };
C41C1B3622B0097F00E7CF16 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; }; C41C1B3622B0097F00E7CF16 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
C41C1B3822B0097F00E7CF16 /* LogViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogViewController.swift; sourceTree = "<group>"; }; C41C1B3822B0097F00E7CF16 /* LogViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogViewController.swift; sourceTree = "<group>"; };
C41C1B3A22B0098000E7CF16 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; }; C41C1B3A22B0098000E7CF16 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
@ -68,7 +67,7 @@
C41C1B3422B0097F00E7CF16 /* Products */ = { C41C1B3422B0097F00E7CF16 /* Products */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
C41C1B3322B0097F00E7CF16 /* phpmon.app */, C41C1B3322B0097F00E7CF16 /* PHP Monitor.app */,
); );
name = Products; name = Products;
sourceTree = "<group>"; sourceTree = "<group>";
@ -147,9 +146,9 @@
/* End PBXGroup section */ /* End PBXGroup section */
/* Begin PBXNativeTarget section */ /* Begin PBXNativeTarget section */
C41C1B3222B0097F00E7CF16 /* phpmon */ = { C41C1B3222B0097F00E7CF16 /* PHP Monitor */ = {
isa = PBXNativeTarget; isa = PBXNativeTarget;
buildConfigurationList = C41C1B4322B0098000E7CF16 /* Build configuration list for PBXNativeTarget "phpmon" */; buildConfigurationList = C41C1B4322B0098000E7CF16 /* Build configuration list for PBXNativeTarget "PHP Monitor" */;
buildPhases = ( buildPhases = (
C41C1B2F22B0097F00E7CF16 /* Sources */, C41C1B2F22B0097F00E7CF16 /* Sources */,
C41C1B3022B0097F00E7CF16 /* Frameworks */, C41C1B3022B0097F00E7CF16 /* Frameworks */,
@ -159,9 +158,9 @@
); );
dependencies = ( dependencies = (
); );
name = phpmon; name = "PHP Monitor";
productName = phpmon; productName = phpmon;
productReference = C41C1B3322B0097F00E7CF16 /* phpmon.app */; productReference = C41C1B3322B0097F00E7CF16 /* PHP Monitor.app */;
productType = "com.apple.product-type.application"; productType = "com.apple.product-type.application";
}; };
/* End PBXNativeTarget section */ /* End PBXNativeTarget section */
@ -179,7 +178,7 @@
}; };
}; };
}; };
buildConfigurationList = C41C1B2E22B0097F00E7CF16 /* Build configuration list for PBXProject "phpmon" */; buildConfigurationList = C41C1B2E22B0097F00E7CF16 /* Build configuration list for PBXProject "PHP Monitor" */;
compatibilityVersion = "Xcode 9.3"; compatibilityVersion = "Xcode 9.3";
developmentRegion = en; developmentRegion = en;
hasScannedForEncodings = 0; hasScannedForEncodings = 0;
@ -192,7 +191,7 @@
projectDirPath = ""; projectDirPath = "";
projectRoot = ""; projectRoot = "";
targets = ( targets = (
C41C1B3222B0097F00E7CF16 /* phpmon */, C41C1B3222B0097F00E7CF16 /* PHP Monitor */,
); );
}; };
/* End PBXProject section */ /* End PBXProject section */
@ -202,7 +201,6 @@
isa = PBXResourcesBuildPhase; isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
C4F8C0A622D4FA41002EFE61 /* README.md in Resources */,
C41C1B3B22B0098000E7CF16 /* Assets.xcassets in Resources */, C41C1B3B22B0098000E7CF16 /* Assets.xcassets in Resources */,
C41C1B3E22B0098000E7CF16 /* Main.storyboard in Resources */, C41C1B3E22B0098000E7CF16 /* Main.storyboard in Resources */,
); );
@ -400,7 +398,7 @@
/* End XCBuildConfiguration section */ /* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */ /* Begin XCConfigurationList section */
C41C1B2E22B0097F00E7CF16 /* Build configuration list for PBXProject "phpmon" */ = { C41C1B2E22B0097F00E7CF16 /* Build configuration list for PBXProject "PHP Monitor" */ = {
isa = XCConfigurationList; isa = XCConfigurationList;
buildConfigurations = ( buildConfigurations = (
C41C1B4122B0098000E7CF16 /* Debug */, C41C1B4122B0098000E7CF16 /* Debug */,
@ -409,7 +407,7 @@
defaultConfigurationIsVisible = 0; defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release; defaultConfigurationName = Release;
}; };
C41C1B4322B0098000E7CF16 /* Build configuration list for PBXNativeTarget "phpmon" */ = { C41C1B4322B0098000E7CF16 /* Build configuration list for PBXNativeTarget "PHP Monitor" */ = {
isa = XCConfigurationList; isa = XCConfigurationList;
buildConfigurations = ( buildConfigurations = (
C41C1B4422B0098000E7CF16 /* Debug */, C41C1B4422B0098000E7CF16 /* Debug */,

View File

@ -1,12 +1,12 @@
# phpmon # PHP Monitor
phpmon is a macOS utility that runs on your Mac and displays the active PHP version in your status bar. PHP Monitor (or phpmon) is a macOS utility that runs on your Mac and displays the active PHP version in your status bar.
<img src="./docs/screenshot.png" width="278px" alt="phpmon screenshot"/> <img src="./docs/screenshot.png" width="278px" alt="phpmon screenshot"/>
For me, it comes in handy when running multiple versions of PHP with Homebrew and you wish to be able to see at a glance which version is currently linked & active with Laravel Valet, and switch between versions. For me, it comes in handy when running multiple versions of PHP with Homebrew and you wish to be able to see at a glance which version is currently linked & active with Laravel Valet, and switch between versions.
This version of phpmon was developed for: This version of PHP Monitor was developed for:
* macOS Mojave (10.14) * macOS Mojave (10.14)
* PHP 7.x with Homebrew 2.x (with support for PHP 5.6 and PHP 7.0 [as well](https://github.com/eXolnet/homebrew-deprecated)) * PHP 7.x with Homebrew 2.x (with support for PHP 5.6 and PHP 7.0 [as well](https://github.com/eXolnet/homebrew-deprecated))

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:phpmon.xcodeproj">
</FileRef>
</Workspace>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

View File

@ -1,6 +1,6 @@
// //
// AppDelegate.swift // AppDelegate.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// Services.swift // Services.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// Environment.swift // Environment.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 12/06/2019. // Created by Nico Verbruggen on 12/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// Alert.swift // Alert.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 12/06/2019. // Created by Nico Verbruggen on 12/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// ImageGenerator.swift // ImageGenerator.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// PhpVersionExtractor.swift // PhpVersionExtractor.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// Constants.swift // Constants.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 08/07/2019. // Created by Nico Verbruggen on 08/07/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// Date.swift // Date.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 09/07/2019. // Created by Nico Verbruggen on 09/07/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -17,9 +17,9 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.3</string> <string>1.4</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>10</string> <string>11</string>
<key>LSApplicationCategoryType</key> <key>LSApplicationCategoryType</key>
<string>public.app-category.utilities</string> <string>public.app-category.utilities</string>
<key>LSMinimumSystemVersion</key> <key>LSMinimumSystemVersion</key>

View File

@ -1,6 +1,6 @@
// //
// StateManager.swift // StateManager.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/07/2019. // Created by Nico Verbruggen on 11/07/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -1,6 +1,6 @@
// //
// MainMenu.swift // MainMenu.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/07/2019. // Created by Nico Verbruggen on 11/07/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.
@ -67,11 +67,11 @@ class MainMenu: NSObject, NSWindowDelegate {
} }
menu.addItem(NSMenuItem(title: "View shell output", action: #selector(self.openOutput), keyEquivalent: "")) menu.addItem(NSMenuItem(title: "View shell output", action: #selector(self.openOutput), keyEquivalent: ""))
menu.addItem(NSMenuItem.separator()) menu.addItem(NSMenuItem.separator())
menu.addItem(NSMenuItem(title: "About phpmon", action: #selector(self.openAbout), keyEquivalent: "")) menu.addItem(NSMenuItem(title: "About PHP Monitor", action: #selector(self.openAbout), keyEquivalent: ""))
menu.items.forEach({ (item) in menu.items.forEach({ (item) in
item.target = self item.target = self
}) })
menu.addItem(NSMenuItem(title: "Quit phpmon", action: #selector(NSApplication.terminate(_:)), keyEquivalent: "q")) menu.addItem(NSMenuItem(title: "Quit PHP Monitor", action: #selector(NSApplication.terminate(_:)), keyEquivalent: "q"))
DispatchQueue.main.async { DispatchQueue.main.async {
self.statusItem.menu = menu self.statusItem.menu = menu
} }

View File

@ -1,6 +1,6 @@
// //
// Shell.swift // Shell.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.

View File

@ -11,18 +11,18 @@
<application id="hnw-xV-0zn" sceneMemberID="viewController"> <application id="hnw-xV-0zn" sceneMemberID="viewController">
<menu key="mainMenu" title="Main Menu" systemMenu="main" id="AYu-sK-qS6"> <menu key="mainMenu" title="Main Menu" systemMenu="main" id="AYu-sK-qS6">
<items> <items>
<menuItem title="phpmon" id="1Xt-HY-uBw"> <menuItem title="PHP Monitor" id="1Xt-HY-uBw">
<modifierMask key="keyEquivalentModifierMask"/> <modifierMask key="keyEquivalentModifierMask"/>
<menu key="submenu" title="phpmon" systemMenu="apple" id="uQy-DD-JDr"> <menu key="submenu" title="PHP Monitor" systemMenu="apple" id="uQy-DD-JDr">
<items> <items>
<menuItem title="About phpmon" id="5kV-Vb-QxS"> <menuItem title="About PHP Monitor" id="5kV-Vb-QxS">
<modifierMask key="keyEquivalentModifierMask"/> <modifierMask key="keyEquivalentModifierMask"/>
<connections> <connections>
<action selector="orderFrontStandardAboutPanel:" target="Ady-hI-5gd" id="Exp-CZ-Vem"/> <action selector="orderFrontStandardAboutPanel:" target="Ady-hI-5gd" id="Exp-CZ-Vem"/>
</connections> </connections>
</menuItem> </menuItem>
<menuItem isSeparatorItem="YES" id="VOq-y0-SEH"/> <menuItem isSeparatorItem="YES" id="VOq-y0-SEH"/>
<menuItem title="Quit phpmon" keyEquivalent="q" id="4sb-4s-VLi"> <menuItem title="Quit PHP Monitor" keyEquivalent="q" id="4sb-4s-VLi">
<connections> <connections>
<action selector="terminate:" target="Ady-hI-5gd" id="Te7-pn-YzF"/> <action selector="terminate:" target="Ady-hI-5gd" id="Te7-pn-YzF"/>
</connections> </connections>
@ -34,7 +34,7 @@
<modifierMask key="keyEquivalentModifierMask"/> <modifierMask key="keyEquivalentModifierMask"/>
<menu key="submenu" title="Help" systemMenu="help" id="F2S-fz-NVQ"> <menu key="submenu" title="Help" systemMenu="help" id="F2S-fz-NVQ">
<items> <items>
<menuItem title="phpmon Help" keyEquivalent="?" id="FKE-Sm-Kum"> <menuItem title="PHP Monitor Help" keyEquivalent="?" id="FKE-Sm-Kum">
<connections> <connections>
<action selector="showHelp:" target="Ady-hI-5gd" id="y7X-2Q-9no"/> <action selector="showHelp:" target="Ady-hI-5gd" id="y7X-2Q-9no"/>
</connections> </connections>
@ -76,7 +76,7 @@
<rect key="frame" x="20" y="46" width="622" height="409"/> <rect key="frame" x="20" y="46" width="622" height="409"/>
<clipView key="contentView" drawsBackground="NO" copiesOnScroll="NO" id="s5L-AU-0fw"> <clipView key="contentView" drawsBackground="NO" copiesOnScroll="NO" id="s5L-AU-0fw">
<rect key="frame" x="1" y="1" width="620" height="407"/> <rect key="frame" x="1" y="1" width="620" height="407"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask"/>
<subviews> <subviews>
<textView importsGraphics="NO" richText="NO" verticallyResizable="YES" smartInsertDelete="YES" id="tN6-Y9-1pA"> <textView importsGraphics="NO" richText="NO" verticallyResizable="YES" smartInsertDelete="YES" id="tN6-Y9-1pA">
<rect key="frame" x="0.0" y="0.0" width="620" height="407"/> <rect key="frame" x="0.0" y="0.0" width="620" height="407"/>
@ -84,7 +84,7 @@
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/> <color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
<size key="minSize" width="620" height="407"/> <size key="minSize" width="620" height="407"/>
<size key="maxSize" width="620" height="10000000"/> <size key="maxSize" width="622" height="10000000"/>
<color key="insertionPointColor" name="textColor" catalog="System" colorSpace="catalog"/> <color key="insertionPointColor" name="textColor" catalog="System" colorSpace="catalog"/>
</textView> </textView>
</subviews> </subviews>

View File

@ -1,6 +1,6 @@
// //
// ViewController.swift // ViewController.swift
// phpmon // PHP Monitor
// //
// Created by Nico Verbruggen on 11/06/2019. // Created by Nico Verbruggen on 11/06/2019.
// Copyright © 2019 Nico Verbruggen. All rights reserved. // Copyright © 2019 Nico Verbruggen. All rights reserved.