Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Lukas Wiest
unified-ticketing
Commits
6a214f11
Verified
Commit
6a214f11
authored
Nov 29, 2020
by
Lukas Wiest
🚂
Browse files
refactor(docs): dev-guide: write initial styleguide page
parent
21de3de7
Pipeline
#1379
passed with stages
in 1 minute and 2 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
docs/developers-guide/styleguide.md
0 → 100644
View file @
6a214f11
# Styleguide
If not explicitly stated otherwise,
the following takes effect for all files:
-
character encoding __utf-8__
-
line endings with __lf__
-
indentation with __4 spaces__
-
final new line
In general,
it's a good idea to have a look into the yet existing code,
to check how certain things were done up to now.
## Java
The most important thing to say here is: opening braces are written into the next line.
_(more to come if s.o. does s.th. differently I didn't think of)_
## Markdown
!!! info "Todo"
write docs
most important bullet points:
-
leave always an empty line above and beneath of lists.
It may render fine in normal markdown viewers,
but not in the MkDocs Pages docs (like this)
??? example inline end
__bad:__
```markdown
some text
- bullet point
- another item
more normal text
```
__good:__
```markdown
some text
- bullet point
- another item
more normal text
```
-
if you insert a link,
__always__ write the link to the bottom of the file with an alias,
ordered alphabetically.
??? example
__bad:__
```markdown
Look [here](https://www.coolsite.not/with/ultra/long/url) to read more about this.
```
__good:__
```markdown
Look [here][coolsite] to read more about this.
[coolsite]: https://www.coolsite.not/with/ultra/long/url
```
-
split long sentences on punctuation and connection words like
`and`
&
`or`
.
It will have the same appearance in viewers,
but be much easier to maintain on code side.
??? example
__bad__:
```markdown
Some sentence that is very long, therefore it has punctuation and has absolutely no sense at all.
```
> Some sentence that is very long, therefore it has punctuation and has absolutely no sense at all.
__good:__
```markdown
Some sentence that is very long,
therefore it has punctuation
and has absolutely no sense at all.
```
> Some sentence that is very long,
> therefore it has punctuation
> and has absolutely no sense at all.
mkdocs.yml
View file @
6a214f11
...
...
@@ -30,6 +30,7 @@ nav:
-
Ticketsystem
:
'
api/systems/gitlab/ticket-system.md'
-
Developers Guide
:
-
Index
:
'
developers-guide/index.md'
-
Styleguide
:
'
developers-guide/styleguide.md'
theme
:
name
:
'
material'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment