Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
walint
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
hub
walint
Commits
ac21c10c
Commit
ac21c10c
authored
3 years ago
by
stuebinm
Browse files
Options
Downloads
Patches
Plain Diff
slight updates to documentation
parent
a572b9e1
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Lints.md
+1
-2
1 addition, 2 deletions
Lints.md
Readme.md
+15
-9
15 additions, 9 deletions
Readme.md
with
16 additions
and
11 deletions
Lints.md
+
1
−
2
View file @
ac21c10c
...
@@ -5,8 +5,7 @@ Note: Most lints (even those not related to properties) are currently defined in
...
@@ -5,8 +5,7 @@ Note: Most lints (even those not related to properties) are currently defined in
## General Tiledmap Requirements
## General Tiledmap Requirements
-
maps must have layers "start" and "floorLayer", and at least one layer wich
-
maps must have layers "start" and "floorLayer", and at least one layer which has as Property "exitUrl"
has as Property "exitUrl"
-
maps must be orthogonal, tile size must be 32 × 32
-
maps must be orthogonal, tile size must be 32 × 32
-
maps must not define their own scripts (unless allowed to do so in
-
maps must not define their own scripts (unless allowed to do so in
the configuration file)
the configuration file)
...
...
This diff is collapsed.
Click to expand it.
Readme.md
+
15
−
9
View file @
ac21c10c
...
@@ -21,8 +21,8 @@ walint --config-file config.json --repository path \
...
@@ -21,8 +21,8 @@ walint --config-file config.json --repository path \
directory.
`walint`
will lint all maps reachable from it. If not given, it
directory.
`walint`
will lint all maps reachable from it. If not given, it
defaults to
`main.json`
defaults to
`main.json`
-
`--lintLevel`
: limit output only to messages that have at most the given
-
`--lintLevel`
: limit output only to messages that have at most the given
level. Valid levels are
`Info`
,
`Suggestion`
,
`Warning`
,
`
Error`
,
`Fatal`
.
level. Valid levels are
`Info`
,
`Suggestion`
,
`Warning`
,
`
Forbidden`
,
`Error`
,
Defaults to
`Suggestion`
if not given.
`Fatal`
.
Defaults to
`Suggestion`
if not given.
-
`--json`
: print output as json instead of the normal more human-friendly format
-
`--json`
: print output as json instead of the normal more human-friendly format
-
`--pretty`
: if used with
`--json`
, insert line breaks and indentation to make
-
`--pretty`
: if used with
`--json`
, insert line breaks and indentation to make
the output more readable. Otherwise no effect.
the output more readable. Otherwise no effect.
...
@@ -30,8 +30,9 @@ walint --config-file config.json --repository path \
...
@@ -30,8 +30,9 @@ walint --config-file config.json --repository path \
json written to this path will be minimised, and
*
only those maps and assets
json written to this path will be minimised, and
*
only those maps and assets
which are reachable from the entrypoint
*
will be writen at all. If not given,
which are reachable from the entrypoint
*
will be writen at all. If not given,
`walint`
will only run the linter and do nothing else. If
`walint`
encounters
`walint`
will only run the linter and do nothing else. If
`walint`
encounters
any references to local map assets which are not present in the repository, it
any references to local map assets which are not present in the repository,
will fail.
or if the map generates lints above the maximum lint level, it will instead
exit with code 1 without touching the output path at all.
-
`--config-file file`
: path to a configuation file. Required (for now).
-
`--config-file file`
: path to a configuation file. Required (for now).
-
`--config json`
: takes a string which should contain a json object conforming
-
`--config json`
: takes a string which should contain a json object conforming
to the same schema as the configuration file, except that all keys are
to the same schema as the configuration file, except that all keys are
...
@@ -51,9 +52,13 @@ you may leave out keys whose type includes `Maybe`)
...
@@ -51,9 +52,13 @@ you may leave out keys whose type includes `Maybe`)
### Output
### Output
By default
`walint`
prints lints in a hopefully human-readable manner. If the
By default
`walint`
prints lints in a hopefully human-readable manner. Its exit
`--json`
option is given, it will instead give a json that should conform to
code will be 1 if the maximum lint level set in its config was exceeded, and 0
the following schema:
otherwise. Only in the latter case will it write out an adjusted map respository
to the path passed to
`--out`
.
If the
`--json`
option is given, output to stdout will be printed as json, which
should conform to the following schema (here defined in a quasi-haskell syntax):
```
haskell
```
haskell
-- | The main type of walint's output
-- | The main type of walint's output
...
@@ -84,8 +89,8 @@ type Where =
...
@@ -84,8 +89,8 @@ type Where =
-- ^ what is this lint's level?
-- ^ what is this lint's level?
}
}
-- | Valid lint levels. Encoded as strings.
-- | Valid lint levels. Encoded as strings
, listed in order here
.
data
Level
=
Info
|
Suggestion
|
Warning
|
Error
|
Fatal
data
Level
=
Info
|
Suggestion
|
Warning
|
Forbidden
|
Error
|
Fatal
-- | description of a single (missing) asset
-- | description of a single (missing) asset
...
@@ -105,3 +110,4 @@ type Entrypoint =
...
@@ -105,3 +110,4 @@ type Entrypoint =
}
}
```
```
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment