Skip to content

Commit

Permalink
add: swiftformat
Browse files Browse the repository at this point in the history
  • Loading branch information
mflknr committed Apr 25, 2024
1 parent 734e954 commit 3c6582f
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
1 change: 1 addition & 0 deletions .mise.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
[tools]
swiftlint = "0.54.0"
swiftformat = "0.53.8"
52 changes: 52 additions & 0 deletions .swiftformat
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# file options

--exclude Tuist,Project.swift

# format options

--allman false
--anonymousforeach convert
--binarygrouping 4,8
--commas inline
--comments indent
--decimalgrouping 3,5
--elseposition same-line
--empty void
--exponentcase lowercase
--exponentgrouping disabled
--fractiongrouping disabled
--header ignore
--hexgrouping 4,8
--hexliteralcase uppercase
--ifdef indent
--indent 4
--indentcase false
--importgrouping testable-bottom
--linebreaks lf
--marktypes never
--maxwidth none
--octalgrouping 4,8
--onelineforeach convert
--operatorfunc spaced
--patternlet hoist
--ranges no-space
--self remove
--semicolons inline
--stripunusedargs always
--swiftversion 5.7
--trimwhitespace always
--typeblanklines preserve
--wraparguments preserve
--wrapcollections preserve

# rules

--enable blankLinesBetweenImports
--enable blockComments
--enable docComments
--enable isEmpty
--enable markTypes
--enable noExplicitOwnership
--enable wrapConditionalBodies
--enable wrapEnumCases
--enable wrapMultilineConditionalAssignment

0 comments on commit 3c6582f

Please sign in to comment.