Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
8e0b6d9
Remove "report" support
unnamedd Apr 14, 2026
b5de4cf
Remove TSC from Project
unnamedd Apr 14, 2026
3c160cc
Add PowerShell in the supported languages
unnamedd Apr 14, 2026
2e8bd36
Add configuration files to the project
unnamedd Apr 14, 2026
f966f9b
Add support to `@raycast.platform` meta tag
unnamedd Apr 14, 2026
2392995
Upgrade `Toolkit` to latest Swift Argument Parser version
unnamedd Apr 14, 2026
6a5d3e7
Add support to Swift async/await
unnamedd Apr 14, 2026
32cc3e2
URL+FileSystem is a replacement for TSC
unnamedd Apr 14, 2026
32e760c
Format project with SwiftFormat
unnamedd Apr 14, 2026
5007778
Upgrade copyright on files headers
unnamedd Apr 14, 2026
6535766
Adjust command `fix` on Makefile
unnamedd Apr 14, 2026
aac6fa9
Upgrade `Toolkit` version
unnamedd Apr 14, 2026
f241901
Improvements for the icon detection
unnamedd Apr 14, 2026
2bd0441
Small changes in the README generation
unnamedd Apr 14, 2026
3d63aa3
Remove `pwsh` from the list of languages in the `extensions.json`
unnamedd Apr 14, 2026
d3ca40e
Update documentation in the main README for the new `@raycast.platform`
unnamedd Apr 14, 2026
fe24b67
Change .swift-version to use Swift 6.0 instead of 6.2
unnamedd Apr 15, 2026
468b947
Update end of line on `.editorconfig`
unnamedd Apr 15, 2026
47a66d8
Merge branch 'master' into improvements-on-toolkit
unnamedd Apr 15, 2026
79a08ff
Fix double space in Makefile fix target
grzegorzkrukowski Apr 24, 2026
060df12
Remove @unchecked from Console Sendable conformance
grzegorzkrukowski Apr 24, 2026
2597909
Revert "Remove @unchecked from Console Sendable conformance"
grzegorzkrukowski Apr 24, 2026
5965067
Add unit tests for ScriptCommand.Platform
grzegorzkrukowski Apr 24, 2026
af5ef4c
Include stderr in GitError description
grzegorzkrukowski Apr 24, 2026
b78006c
Revert generated README title to "Raycast Script Commands"
grzegorzkrukowski Apr 24, 2026
2c0413b
Fix script path truncation by centralizing relative path computation
grzegorzkrukowski Apr 24, 2026
1598245
Sort script commands and groups at all levels for deterministic JSON …
grzegorzkrukowski Apr 24, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,36 +7,53 @@ EXECUTABLE_PATH_RELEASE = $(BUILD_PATH_RELEASE)/Toolkit
BUILD_PATH_DEBUG = $(TOOLKIT_PATH)/.build/debug
EXECUTABLE_PATH_DEBUG = $(BUILD_PATH_DEBUG)/Toolkit

.PHONY: clean
clean:
rm -rf $(TOOLKIT_PATH)/.build $(EXECUTABLE_NAME)

.PHONY: build
build: clean
swift build -c release --disable-sandbox --package-path $(TOOLKIT_PATH)
ln -s $(EXECUTABLE_PATH_RELEASE) $(EXECUTABLE_NAME)

.PHONY: build-debug
build-debug:
if [ -f $(EXECUTABLE_NAME) ]; then rm $(EXECUTABLE_NAME); fi

swift build --package-path $(TOOLKIT_PATH)
ln -s $(EXECUTABLE_PATH_DEBUG) $(EXECUTABLE_NAME)

.PHONY: gen-docs
gen-docs:
./$(EXECUTABLE_NAME) generate-documentation

.PHONY: gen-docs-and-commit
gen-docs-and-commit: gen-docs
./$(TOOLKIT_PATH)/integration.sh commit_documentation

.PHONY: set-executable
set-executable:
./$(EXECUTABLE_NAME) set-executable

.PHONY: set-executable-and-commit
set-executable-and-commit: set-executable
./$(TOOLKIT_PATH)/integration.sh commit_executable

.PHONY: lint
lint:
swiftlint lint
@echo "Linting code format with SwiftLint"
@swiftlint $(TOOLKIT_PATH) --config $(TOOLKIT_PATH)/.swiftlint.yml

.PHONY: fix
fix:
swiftlint --fix
@echo "Fixing code format with SwiftLint"
@swiftlint $(TOOLKIT_PATH) --fix --config $(TOOLKIT_PATH)/.swiftlint.yml

.PHONY: format
format:
@echo "Fixing code format with SwiftFormat"
@swiftformat $(TOOLKIT_PATH) --config $(TOOLKIT_PATH)/.swiftformat

.PHONY: open
open:
open -a /Applications/Xcode.app $(TOOLKIT_PATH)
64 changes: 34 additions & 30 deletions README.md

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions Tools/Toolkit/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[*.swift]
indent_style = space
indent_size = 2
tab_width = 2
end_of_line = lf
insert_final_newline = true
max_line_length = 120
trim_trailing_whitespace = true

[*.ps1]
end_of_line = crlf
1 change: 1 addition & 0 deletions Tools/Toolkit/.swift-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
6.0
162 changes: 162 additions & 0 deletions Tools/Toolkit/.swiftformat
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
--acronyms ID,URL,UUID
--allman false
--anonymousforeach convert
--assetliterals visual-width
--asynccapturing
--beforemarks
--binarygrouping 4,8
--callsiteparen default
--categorymark "MARK: %c"
--classthreshold 0
--closingparen balanced
--closurevoid remove
--commas always
--complexattrs preserve
--computedvarattrs preserve
--condassignment after-property
--conflictmarkers reject
--dateformat system
--decimalgrouping 3,6
--doccomments before-declarations
--emptybraces no-space
--enumnamespaces always
--enumthreshold 0
--equatablemacro none
--exponentcase lowercase
--exponentgrouping disabled
--extensionacl on-extension
--extensionlength 0
--extensionmark "MARK: - %t + %c"
--filemacro "#file"
--fractiongrouping disabled
--fragment false
--funcattributes prev-line
--generictypes
--groupblanklines true
--groupedextension "MARK: - %c"
--guardelse next-line
--header strip
--hexgrouping 4,8
--hexliteralcase uppercase
--ifdef indent
--importgrouping alpha
--indent 2
--indentcase false
--indentstrings false
--inferredtypes always
--initcodernil false
--inlinedforeach ignore
--lifecycle
--lineaftermarks true
--linebreaks lf
--markcategories true
--markextensions always
--marktypes always
--maxwidth 120
--modifierorder
--nevertrailing
--nilinit remove
--noncomplexattrs
--nospaceoperators
--nowrapoperators
--octalgrouping 4,8
--operatorfunc spaced
--organizationmode visibility
--organizetypes actor,class,enum,struct
--patternlet hoist
--preservedecls
--preserveacronyms
--preservedsymbols Package
--propertytypes infer-locals-only
--ranges spaced
--self remove
--selfrequired
--semicolons inline
--shortoptionals except-properties
--smarttabs enabled
--someany true
--sortedpatterns
--sortswiftuiprops none
--storedvarattrs preserve
--stripunusedargs always
--structthreshold 0
--tabwidth unspecified
--throwcapturing
--timezone system
--trailingclosures
--trimwhitespace always
--typeattributes prev-line
--typeblanklines remove
--typedelimiter space-after
--typemark "MARK: - %t"
--typemarks
--typeorder
--visibilitymarks
--visibilityorder
--voidtype void
--wraparguments before-first
--wrapcollections before-first
--wrapconditions preserve
--wrapeffects preserve
--wrapenumcases always
--wrapparameters default
--wrapreturntype preserve
--wrapternary default
--wraptypealiases preserve
--xcodeindentation disabled
--xctestsymbols
--yodaswap always

--enable acronyms
--enable blankLineAfterSwitchCase
--enable isEmpty
--enable markTypes
--enable redundantVariable
--enable sortSwitchCases
--enable wrapConditionalBodies
--enable wrapEnumCases
--enable wrapSwitchCases

--disable assertionFailures
--disable blankLinesAtStartOfScope
--disable blankLinesBetweenChainedFunctions
--disable braces
--disable docCommentsBeforeModifiers
--disable extensionAccessControl
--disable genericExtensions
--disable headerFileName
--disable initCoderUnavailable
--disable leadingDelimiters
--disable linebreakAtEndOfFile
--disable linebreaks
--disable modifierOrder
--disable numberFormatting
--disable opaqueGenericParameters
--disable preferForLoop
--disable redundantNilInit
--disable redundantType
--disable redundantVoidReturnType
--disable spaceAroundBraces
--disable spaceAroundBrackets
--disable spaceAroundComments
--disable spaceAroundGenerics
--disable spaceAroundOperators
--disable spaceAroundParens
--disable spaceInsideBraces
--disable spaceInsideBrackets
--disable spaceInsideGenerics
--disable strongOutlets
--disable strongifiedSelf
--disable typeSugar
--disable unusedArguments
--disable void
--disable wrap
--disable wrapArguments
--disable wrapAttributes
--disable wrapLoopBodies
--disable wrapMultilineStatementBraces
--disable wrapSingleLineComments
--disable yodaConditions

--enable fileHeader
--header \nMIT License\nCopyright (c) 2020-{year} Raycast. All rights reserved.\n
12 changes: 4 additions & 8 deletions .swiftlint.yml → Tools/Toolkit/.swiftlint.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
indentation: 2
included:
- Tools/Toolkit
excluded:
- Tools/Toolkit/.build
- .build
- _enabled-commands
- commands
- templates
disabled_rules:
- cyclomatic_complexity
- file_length
Expand All @@ -14,7 +10,6 @@ disabled_rules:
- todo # Use custom_todo
- unused_setter_value
- generic_type_name
- identifier_name
- function_parameter_count
- type_name
- function_body_length
Expand All @@ -33,11 +28,12 @@ opt_in_rules:
- file_header
- overridden_super_call
- sorted_imports
- unused_declaration
- unused_import
- vertical_whitespace_closing_braces
- vertical_whitespace_opening_braces
- yoda_condition
analyzer_rules:
- unused_declaration
- unused_import
indentation_width:
indentation_width: 2
trailing_comma:
Expand Down
34 changes: 12 additions & 22 deletions Tools/Toolkit/Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 10 additions & 15 deletions Tools/Toolkit/Package.swift
Original file line number Diff line number Diff line change
@@ -1,39 +1,34 @@
// swift-tools-version:5.3
// swift-tools-version:6.0

import PackageDescription

let package = Package(
name: "toolkit",
platforms: [
.macOS(.v11),
.macOS(.v13),
],
dependencies: [
.package(
url: "https://github.com/apple/swift-tools-support-core.git",
.upToNextMinor(from: "0.2.4")
),
.package(
url: "https://github.com/apple/swift-argument-parser.git",
.upToNextMinor(from: "1.0.0")
.upToNextMajor(from: "1.5.0"),
),
],
targets: [
.target(
.executableTarget(
name: "Toolkit",
dependencies: [
"ToolkitLibrary",
.product(name: "SwiftToolsSupport-auto", package: "swift-tools-support-core"),
.product(name: "ArgumentParser", package: "swift-argument-parser"),
]
],
),
.target(
name: "ToolkitLibrary",
dependencies: [
.product(name: "SwiftToolsSupport-auto", package: "swift-tools-support-core"),
]
dependencies: [],
),
.testTarget(
name: "ToolkitLibraryTests",
dependencies: ["ToolkitLibrary"]),
]
dependencies: ["ToolkitLibrary"],
),
],
swiftLanguageModes: [.v6],
)
Loading