Skip to content

Commit bb2fc95

Browse files
authored
Merge pull request #2 from wayofdev/feat/base-poc-1
feat: add phar build
2 parents 895c629 + 2f82a21 commit bb2fc95

File tree

11 files changed

+370
-41
lines changed

11 files changed

+370
-41
lines changed

.cursor/branding-guidelines.md

Lines changed: 242 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,242 @@
1+
# Phony Branding Guidelines
2+
3+
This document defines the **final, approved brand identity** for **Phony** — a PHP developer tool orchestrator. It explains *what Phony is*, *why it is called Phony*, and *how the brand must be represented* visually and verbally.
4+
5+
This is the **single source of truth** for branding decisions.
6+
7+
---
8+
9+
## Brand Overview
10+
11+
| Attribute | Value |
12+
|----------------|-----------------------------|
13+
| **Name** | Phony |
14+
| **Package** | `wayofdev/phony` |
15+
| **Namespace** | `WayOfDev\\Phony` |
16+
| **Binary** | `phony` |
17+
| **Repository** | `github.com/wayofdev/phony` |
18+
19+
---
20+
21+
## Brand Rationale: Why “Phony”?
22+
23+
The name **Phony** is intentionally ironic.
24+
25+
At first glance, Phony looks like a single CLI tool. In reality, it is an **orchestrator** — a facade that coordinates multiple best-in-class PHP quality tools behind one simple interface.
26+
27+
In this sense, Phony is *“phony”* in the same way many software abstractions are:
28+
29+
> it presents a simplified surface while hiding real complexity underneath.
30+
31+
This deliberate illusion is a **feature, not a flaw**.
32+
33+
Phony does not replace existing tools —
34+
it *pretends* to be one tool so developers don’t have to think about many.
35+
36+
This mirrors familiar software concepts:
37+
38+
* Facade pattern
39+
* Adapter
40+
* Proxy
41+
* Unified interface over complex systems
42+
43+
The name rewards curiosity: once understood, it feels *earned*.
44+
45+
---
46+
47+
## Brand Mantra
48+
49+
> **One stable. One command. Trusted PHP quality.**
50+
51+
Alternative internal phrasing (not for logo use):
52+
53+
* *A friendly facade over serious tooling*
54+
* *Simple on the surface. Powerful underneath.*
55+
56+
---
57+
58+
## Mental Model (ASCII)
59+
60+
This is how Phony should be understood architecturally and conceptually:
61+
62+
```text
63+
┌──────────────┐
64+
│ phony │ ← one command, one interface
65+
└──────┬───────┘
66+
67+
68+
┌──────────────────────────────┐
69+
│ linters • formatters • SAST │
70+
│ analyzers • custom checks │
71+
│ best-in-class PHP tools │
72+
└──────────────────────────────┘
73+
```
74+
75+
Phony is the **stable master**, not the horse.
76+
77+
---
78+
79+
## Mascot (FINAL)
80+
81+
### Concept
82+
83+
**Illustrated / plush elephant–pony hybrid** inspired by the official PHP **elePHPant** mascot.
84+
85+
* Elephant head → PHP heritage
86+
* Pony body → speed, elegance, agility
87+
* Hybrid → intentional abstraction
88+
89+
This mascot is **not realistic**. It is friendly, symbolic, and recognizably PHP-native.
90+
91+
### Anatomy
92+
93+
* **Head:** Elephant-like, short rounded trunk, big friendly eyes, round ears
94+
* **Body:** Compact pony body, plush proportions
95+
* **Pose:** One front hoof slightly raised (confidence + friendliness)
96+
* **Mane & Tail:** Flowing, stylized, adds motion
97+
98+
---
99+
100+
## Color Palette (FINAL)
101+
102+
| Usage | Hex |
103+
|-----------------|-----------------------------|
104+
| Primary body | `#777BB4` (PHP purple-blue) |
105+
| Body shading | darker purple tones |
106+
| Mane & tail | `#CD853F``#DAA520` |
107+
| Eyes | `#FFFFFF` + dark pupils |
108+
| Text (light UI) | `#333333` |
109+
| Text (dark UI) | `#E6EDF3` |
110+
111+
---
112+
113+
## Logo System
114+
115+
### Composition
116+
117+
* Mascot on the **left**
118+
* Wordmark **“Phony”** on the right
119+
* Optional tagline below
120+
121+
### Geometry Rule (MANDATORY)
122+
123+
The tagline must align **exactly under the left edge of the “P”** in “Phony”.
124+
125+
```text
126+
P h o n y
127+
|
128+
Your PHP quality stable
129+
```
130+
131+
No centering by eye. This is a hard alignment rule.
132+
133+
---
134+
135+
## Tagline
136+
137+
**Primary tagline:**
138+
139+
> **Your PHP quality stable**
140+
141+
Meaning:
142+
143+
* *Stable (noun)* — a collection of tools
144+
* *Stable (adjective)* — reliable, trustworthy quality
145+
146+
The tagline is **optional** and only used in full logo variants.
147+
148+
---
149+
150+
## Theme Variants (GitHub)
151+
152+
Two official variants are required.
153+
154+
### Light Theme
155+
156+
* Optimized for white backgrounds
157+
* Tagline text: dark gray (`#333333`) or deep purple-gray
158+
159+
### Dark Theme
160+
161+
* Optimized for GitHub dark (`#0d1117`)
162+
* Tagline text: near-white (`#E6EDF3`)
163+
* Purple tones slightly brightened for contrast
164+
165+
No glow, no background fills.
166+
167+
---
168+
169+
## Canonical Logo Generation Prompt (LOCKED)
170+
171+
```text
172+
Create a high-quality illustrated mascot logo for a PHP developer CLI tool named “Phony”
173+
(PHP + Pony = Phony). Output with a fully transparent background (alpha).
174+
175+
Mascot (left):
176+
- Cute elephant–pony hybrid inspired by the PHP elePHPant plush style
177+
- Elephant head, short rounded trunk, big friendly eyes, round ears
178+
- Compact pony body, plush proportions, one front hoof slightly raised
179+
- Flowing mane and tail with motion
180+
181+
Colors:
182+
- Body: PHP purple-blue (#777BB4) with darker purple shading
183+
- Mane & tail: warm chestnut / amber (#CD853F to #DAA520)
184+
- Eyes: white with dark pupils and highlight
185+
186+
Wordmark (right):
187+
- Text: “Phony”
188+
- Bold modern developer-friendly typography
189+
- Two-tone: “Ph” in purple, “ony” in warm chestnut/orange
190+
191+
Tagline (optional second line):
192+
- “Your PHP quality stable”
193+
- MUST align exactly under the left edge of the “P” in “Phony”
194+
195+
Composition:
196+
- Mascot left, wordmark right, tagline below
197+
- Transparent background only
198+
- Crisp edges suitable for SVG redraw
199+
```
200+
201+
---
202+
203+
## Asset Naming Convention
204+
205+
```text
206+
assets/
207+
├── logo.svg
208+
├── logo.gh-light-mode-only.svg
209+
├── logo.gh-dark-mode-only.svg
210+
├── logo-icon.svg
211+
├── logo-icon-512.png
212+
├── favicon.ico
213+
└── social-preview.png
214+
```
215+
216+
---
217+
218+
## README.md Structure (Recommended)
219+
220+
The README should reinforce the brand narrative:
221+
222+
1. **Logo (auto light/dark switch)**
223+
2. **One-sentence value proposition**
224+
3. **Short explanation of “phony” (facade metaphor)**
225+
4. **What Phony does / does not do**
226+
5. **Quick start**
227+
6. **Tool ecosystem (what it orchestrates)**
228+
7. **Configuration philosophy**
229+
8. **Contributing & design principles**
230+
231+
---
232+
233+
## Brand Positioning Summary
234+
235+
Phony is:
236+
237+
* Friendly, not corporate
238+
* Honest about abstraction
239+
* PHP-native, not generic
240+
* Simple on the surface, serious underneath
241+
242+
> **Phony is a deliberate illusion — built to make PHP quality boringly reliable.**

.github/workflows/coding-standards.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ jobs:
122122
uses: wayofdev/gh-actions/actions/phive/install@v3.3.0
123123
with:
124124
phive-home: '.phive'
125-
trust-gpg-keys: '0xC00543248C87FB13,0x033E5F8D801A2F8D'
125+
trust-gpg-keys: '0xC00543248C87FB13,0x033E5F8D801A2F8D,0x2DF45277AEF09A2F'
126126

127127
- name: 🔍 Run ergebnis/composer-normalize
128128
run: .phive/composer-normalize --ansi --dry-run

.github/workflows/dependency-analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ jobs:
7777
uses: wayofdev/gh-actions/actions/phive/install@v3.3.0
7878
with:
7979
phive-home: '.phive'
80-
trust-gpg-keys: 0xC00543248C87FB13,0x033E5F8D801A2F8D
80+
trust-gpg-keys: 0xC00543248C87FB13,0x033E5F8D801A2F8D,0x2DF45277AEF09A2F
8181

8282
- name: 🔬 Run maglnet/composer-require-checker
8383
run: .phive/composer-require-checker check --ansi --config-file="$(pwd)/composer-require-checker.json" --verbose

.phive/phars.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
<phive xmlns="https://phar.io/phive">
33
<phar name="composer-normalize" version="^2.48.0" installed="2.48.2" location="./.phive/composer-normalize" copy="false"/>
44
<phar name="composer-require-checker" version="^4.20.0" installed="4.20.0" location="./.phive/composer-require-checker" copy="false"/>
5+
<phar name="box-project/box" version="^4.6.10" installed="4.6.10" location="./.phive/box" copy="false"/>
56
</phive>

Makefile

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,19 @@ update: ## Updates composer dependencies by running composer update command
177177
.PHONY: update
178178

179179
phive: ## Installs dependencies with phive
180-
$(APP_RUNNER) /usr/local/bin/phive install --trust-gpg-keys 0xC00543248C87FB13,0x033E5F8D801A2F8D
180+
$(APP_RUNNER) /usr/local/bin/phive install --trust-gpg-keys 0xC00543248C87FB13,0x033E5F8D801A2F8D,0x2DF45277AEF09A2F
181181
.PHONY: phive
182182

183+
phar: ## Builds the PHAR archive
184+
$(APP_RUNNER) sh -c "git config --global --add safe.directory /app \
185+
&& composer install --no-dev --optimize-autoloader --classmap-authoritative \
186+
&& .phive/box validate \
187+
&& .phive/box compile \
188+
&& .phive/box info .build/phar/phony.phar \
189+
&& .build/phar/phony.phar \
190+
&& composer install"
191+
.PHONY: phar
192+
183193
#
184194
# Code Quality, Git, Linting
185195
# ------------------------------------------------------------------------------------

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
<p align="center">
2-
<br>
32
<a href="https://wayof.dev" target="_blank">
43
<picture>
5-
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/wayofdev/.github/master/assets/logo.gh-dark-mode-only.png">
6-
<img width="400" src="https://raw.githubusercontent.com/wayofdev/.github/master/assets/logo.gh-light-mode-only.png" alt="WayOfDev Logo">
4+
<source media="(prefers-color-scheme: dark)" srcset="assets/logo.png">
5+
<img width="600" src="assets/logo.png" alt="WayOfDev Logo">
76
</picture>
87
</a>
9-
<br>
108
</p>
119

1210
<p align="center">

assets/logo.png

448 KB
Loading

bin/phony

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/usr/bin/env php
2+
<?php
3+
4+
declare(strict_types=1);
5+
6+
use WayOfDev\Phony\Application;
7+
8+
// Find autoloader
9+
$autoloadPaths = [
10+
__DIR__ . '/../vendor/autoload.php',
11+
__DIR__ . '/../../../autoload.php',
12+
];
13+
14+
$autoloadFound = false;
15+
foreach ($autoloadPaths as $autoloadPath) {
16+
if (file_exists($autoloadPath)) {
17+
require $autoloadPath;
18+
$autoloadFound = true;
19+
break;
20+
}
21+
}
22+
23+
if (! $autoloadFound) {
24+
fwrite(STDERR, "Could not find autoloader. Run 'composer install' first.\n");
25+
exit(1);
26+
}
27+
28+
$application = new Application();
29+
$application->run();

box.json

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
{
2+
"$schema": "https://raw.githubusercontent.com/box-project/box/main/res/schema.json",
3+
"alias": "phony.phar",
4+
"compactors": [
5+
"KevinGH\\Box\\Compactor\\Php"
6+
],
7+
"compression": "GZ",
8+
"directories": [
9+
"src"
10+
],
11+
"files": [
12+
"bin/phony",
13+
"LICENSE.md",
14+
"composer.json",
15+
"composer.lock"
16+
],
17+
"finder": [
18+
{
19+
"name": "*.php",
20+
"exclude": [
21+
"Tests",
22+
"tests",
23+
"test",
24+
"spec"
25+
],
26+
"in": "vendor"
27+
},
28+
{
29+
"name": "*",
30+
"in": "vendor/symfony/console/Resources"
31+
},
32+
{
33+
"name": "*.json",
34+
"in": "vendor/ergebnis/composer-normalize/resource"
35+
},
36+
{
37+
"name": "*.json",
38+
"in": "vendor/maglnet/composer-require-checker/data"
39+
}
40+
],
41+
"replacement-sigil": "@",
42+
"output": ".build/phar/phony.phar"
43+
}

composer.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@
4242
"vimeo/psalm": "^6.14",
4343
"wayofdev/cs-fixer-config": "^1.5"
4444
},
45+
"minimum-stability": "dev",
46+
"prefer-stable": true,
4547
"autoload": {
4648
"psr-4": {
4749
"WayOfDev\\Phony\\": "src/"
@@ -52,6 +54,9 @@
5254
"WayOfDev\\Tests\\": "tests/src/"
5355
}
5456
},
57+
"bin": [
58+
"bin/phony"
59+
],
5560
"config": {
5661
"allow-plugins": {
5762
"ergebnis/composer-normalize": true,

0 commit comments

Comments
 (0)