Skip to content

v0.5.1-alpha

Pre-release
Pre-release

Choose a tag to compare

@github-actions github-actions released this 24 Nov 08:04
· 18 commits to main since this release

What's new in 0.5.1-alpha

  • The per-project folder is now invisible to git: .phpcraft is created through config::project_dir(), which writes a .gitignore of * inside it, so the session, run configurations, interpreter, deployment, data sources and the project dictionary never appear as untracked files in the user's repository and no manual ignore rule is needed — an edited ignore file is left alone, so a team can share the folder deliberately. Every writer goes through the helper, a stray .phpcraft/session.json that a dev run of the app had committed is removed from the index and the folder is listed in the repository's own .gitignore as a second line of defence.
  • Buttons and tool windows now name their text colour instead of trusting the window default: a div that sets no colour inherits black, which is invisible on the dark panels, so every secondary dialog button ("Commit and Push", the merge window's "Use Local", the data-source buttons and the rest) drew its label in black, and any plain label in a tool window could too. dialogs::button now sets theme::ui_text() for the bordered variant and keeps white on the accent-filled one, the tool-window panel and the workspace root both carry theme::ui_text() as their inherited colour, and the commit footer puts the plain Commit action on the left and Commit and Push on the right so the two are read as separate buttons.
  • The Debug window now owns breakpoints: it lists every breakpoint of the project with the PHP condition each one carries, a pencil opens the condition for editing (an empty answer removes it), the cross deletes the breakpoint, and the gutter draws a ring instead of a solid dot wherever the breakpoint only stops on a condition — the protocol already sent condition with breakpoint_set, but nothing in the UI could ever write one, so conditional breakpoints were unreachable. breakpoints::set_condition updates or creates one breakpoint and saves; editing from the window re-reads the store into every open editor so their anchors do not overwrite the condition on the next save, and the running session is told through breakpoints_changed.
  • Intention actions (⌥↵) now come from the analysis crates as a template plus the values that filled it, the same way inspection messages already do, so the menu is rendered through i18n::trf and Russian word order works: a php_analysis::Intention gained template and params next to the built English label, Intention::new builds both in one place, i18n::intention translates one for display, and every PHP and Laravel intention — quotes, concatenation, flip, array syntax, closures, visibility, nullable types, invert if, import class, unused variable, facade to injection, validation rules, #[Scope] — carries its wording instead of a finished sentence. The spelling quick fixes ("Change to '…'", "Save '…' to project dictionary") and the unused-variable fix in the ⌥↵ menu go through the same lookup, and fill_template moved to the crate root so inspections and intentions share it.
  • Tidy the handoff notes: the intention labels are already listed in the localization gap, so the gap list no longer repeats them.
  • Files changed on disk are now watched by the operating system instead of being polled every two seconds: the platform watcher (FSEvents, ReadDirectoryChangesW, inotify through notify) is registered on the folders of the open tabs only, so vendor and node_modules cost nothing, it grows and shrinks as tabs come and go, read-only access events are dropped, and a file that is still being written is skipped until its stamp settles — a save that ends up in half a file can never reach a buffer. Changes that arrive while the window is in the background queue their question and are asked on return, and answering "Reload" reads the file once more instead of trusting the copy captured when the question was raised. The same wave makes the analysis crates translatable: a php_analysis::Problem now carries the English template and the values that went into it alongside the built sentence, so the app renders inspections — and the messages of PHPStan, Psalm, PHPCS and a merge conflict — through i18n::trf into Russian word order, and the About text goes through tr/trf as well.
  • Structural search: Edit ▸ Structural Search… (⌥⌘F, also a Search Everywhere row) searches the project for a pattern written in PHP tokens with $A$ holes instead of text, so $A$->where($B$) finds every where call whatever its formatting, comments or line breaks, a hole never runs past a ;, and a hole used twice must stand for the same expression both times; the tokenizer in crates/search/src/structural.rs treats strings, heredocs and comments as single tokens, holes must stay balanced, and the replacement fills the holes back ($A$->filter($B$)) across every file with hits, recording them in Local History as "Before Structural Replace" and reporting the count in the Output panel. The dialog follows Find in Files: a live result list with the hit highlighted and path:line on the right, *.php mask (or any globs, plus vendor), double-click to jump, Enter to open the selected hit, and Replace All.
  • Run Anything: a double tap of Ctrl (or ⌥⌘↵, Run ▸ Run Anything…, and the same entry in Search Everywhere) opens one field over the whole project's way of starting something — saved and detected run configurations, the Artisan command list (cached, fetched off the UI thread the first time), the lines typed into it before, and the line being typed. Enter runs the selected row; Tab puts an Artisan command into the field so its arguments can be appended, Shift+Enter still saves a configuration, and a line that names no command falls through to the shell, so php -v, git status or composer dump-autoload need no configuration at all. A typed line whose first word is an Artisan command runs through php artisan with the rest as arguments, and every executed line is remembered newest first in .phpcraft/run.json (history, capped at 30, deduplicated), which is what the Recent section lists. The double-modifier detection is now shared with ⇧⇧ Search Everywhere, and the dialog's rows carry the command each configuration expands to as their detail line.

Made with ❤️ in Azerbaijan · https://path.az