1
0

style-guide.ko.md 5.9 KB

์Šคํƒ€์ผ ๊ฐ€์ด๋“œ

์ด ํŽ˜์ด์ง€๋Š” tldr ํŽ˜์ด์ง€์— ๋Œ€ํ•œ ํ˜•์‹ ์ง€์ • ์ง€์นจ๋“ค์„ ๋‚˜์—ดํ•ฉ๋‹ˆ๋‹ค.

๋ ˆ์ด์•„์›ƒ

๊ฐ ํŽ˜์ด์ง€์˜ ๊ธฐ๋ณธ ํฌ๋งท์€ ๋‹ค์Œ ํ…œํ”Œ๋ฆฟ๊ณผ ์ผ์น˜ํ•ด์•ผ ํ•˜๋ฉฐ, ๋‹ค์Œ๊ณผ ์ตœ๋Œ€ 8๊ฐœ์˜ ๋ช…๋ น์–ด ์˜ˆ์ œ๋ฅผ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค:

# ๋ช…๋ น์–ด ์ด๋ฆ„

> ์งง๊ณ  ๊ฐ„๊ฒฐํ•œ ์„ค๋ช…
> ๋ณดํ†ต 1์ค„, ํ•„์š”ํ•œ 2์ค„ ๊นŒ์ง€ ํ—ˆ์šฉ๋จ
> ๋” ๋งŽ์€ ์ •๋ณด: <https://example.com/command_name/help/page>.

- ์ฝ”๋“œ ์„ค๋ช…:

`command_name options`

- ์ฝ”๋“œ ์„ค๋ช…:

`command_name options`

...

์˜ˆ์‹œ:

# ๋ช…๋ น์–ด ์ด๋ฆ„

# krita

> krita๋Š” ๋””์ง€ํ„ธ ์•„ํ‹ฐ์ŠคํŠธ๋ฅผ ์œ„ํ•ด ์„ค๊ณ„๋œ ์Šค์ผ€์น˜/ํŽ˜์ธํŒ… ํ”„๋กœ๊ทธ๋žจ์ž…๋‹ˆ๋‹ค.
> `gimp` ํŽ˜์ด์ง€๋„ ์ฐธ์กฐํ•˜์„ธ์š”.
> ๋” ๋งŽ์€ ์ •๋ณด: <https://docs.krita.org/en/reference_manual/linux_command_line.html>.

- krita ์‹œ์ž‘:

`krita`

- ๋กœ๋”ฉ ํ™”๋ฉด ์—†์ด ์‹œ์ž‘:

`krita --nosplash`

- ํŠน์ • ํŒŒ์ผ ์—ด๊ธฐ:

`krita {{path/to/image1 path/to/image2 ...}}`

- ํŠน์ • workspace (`Animation`) ์—์„œ ์‹œ์ž‘:

`krita --workspace {{Animation}}`

- ์ „์ฒดํ™”๋ฉด์œผ๋กœ ์‹œ์ž‘:

`krita --fullscreen`

:bulb: ๋„์›€๋ง ํŽ˜์ด์ง€๋Š” ๋งค๋‰ด์–ผ ๋ฟ ์•„๋‹ˆ๋ผ ๋ฌธ์„œ, ํ”„๋กœ์ ํŠธ, ํŠœํ† ๋ฆฌ์–ผ ๋“ฑ์ด ๋  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ๊ทธ๋Ÿฌ๋‚˜, ๋ฌธ์„œ ํŽ˜์ด์ง€๋ฅผ ๊ถŒ์žฅํ•ฉ๋‹ˆ๋‹ค.

์œ„์˜ ํ˜•์‹๋“ค์„ ๊ฐ•์ œํ•˜๋Š” linter๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค. ๋ชจ๋“  pull ์š”์ฒญ์— ๋Œ€ํ•ด ์ž๋™์œผ๋กœ ์‹คํ–‰๋˜์ง€๋งŒ, ์ œ์ถœํ•˜๊ธฐ ์ „ local์—์„œ ํ…Œ์ŠคํŠธํ•˜๊ธฐ ์œ„ํ•ด ์„ค์น˜ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

npm install --global tldr-lint
tldr-lint path/to/tldr_page.md

tldr-lint๋ฅผ ์‚ฌ์šฉํ•˜๊ธฐ ์œ„ํ•œ ์—ฌ๋Ÿฌ ๋ฐฉ๋ฒ•๋“ค์ด ๋งŽ์Šต๋‹ˆ๋‹ค. ๋‹ค์Œ์€ ์ด์— ๋Œ€ํ•œ ์•ˆ๋‚ด ํŽ˜์ด์ง€์ž…๋‹ˆ๋‹ค. ํ™•์ธํ•ด ๋ณด์„ธ์š”! tldr tldr-lint.

๋ณ„์นญ tldrl์„ ์“ธ ์ˆ˜๋„ ์žˆ์Šต๋‹ˆ๋‹ค.

Client๋Š” --render ๋ช…๋ น์–ด๋ฅผ ํ†ตํ•ด local์—์„œ ํŽ˜์ด์ง€๋ฅผ ๋ฏธ๋ฆฌ ๋ณผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

tldr --render path/to/tldr_page.md

Aliases

๋งŒ์•ฝ ๋ช…๋ น์–ด๋ฅผ ๋‹ค๋ฅธ ๋ณ„์นญ์œผ๋กœ ๋ถ€๋ฅผ ์ˆ˜ ์žˆ๋Š” ๊ฒฝ์šฐ (ex: vim๊ณผ vi) ์‚ฌ์šฉ์ž๊ฐ€ ์›๋ž˜ ๋ช…๋ น ์ด๋ฆ„์„ ๊ฐ€๋ฆฌํ‚ค๋„๋ก ๋ณ„์นญ ํŽ˜์ด์ง€๋ฅผ ๋งŒ๋“ค ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

# ๋ช…๋ น์–ด ์ด๋ฆ„

> ์ด ๋ช…๋ น์–ด๋Š” `originam-command-name`์˜ ๋ณ„์นญ์ž…๋‹ˆ๋‹ค.
> ๋” ๋งŽ์€ ์ •๋ณด๋Š” <https://example.com/original/command/help/page>๋ฅผ ์ฐธ์กฐํ•˜์„ธ์š”.

- ์›๋ž˜ ๋ช…๋ น์–ด์— ๋Œ€ํ•œ ๋ฌธ์„œ:

`tldr vim`

  • ๋ฒˆ์—ญ๋œ ๋ณ„์นญ ํŽ˜์ด์ง€ ํ…œํ”Œ๋ฆฟ์€ ์—ฌ๊ธฐ์—์„œ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

Token syntax

์‚ฌ์šฉ์ž ์ž…๋ ฅ ๊ฐ’์€ tldr ํด๋ผ์ด์–ธํŠธ์—๊ฒŒ ๊ฐ•์กฐ๋  ์ˆ˜ ์žˆ๋„๋ก {{token}} ๊ตฌ๋ฌธ์„ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

ํ† ํฐ์„ ์„ ํƒํ•  ๋•Œ ๋‹ค์Œ์˜ ๊ฐ€์ด๋“œ๋ผ์ธ์„ ์—ผ๋‘์— ๋‘์‹ญ์‹œ์˜ค:

Naming

  • ์งง์ง€๋งŒ ์„ค๋ช…์ ์ธ ํ† ํฐ์„ ์‚ฌ์šฉํ•˜์„ธ์š”.
  • ํŒŒ์ผ ๋ฐ ๋””๋ ‰ํ† ๋ฆฌ ๊ฒฝ๋กœ์— ๋Œ€ํ•œ ์ฐธ์กฐ์˜ ๊ฒฝ์šฐ: {{path/to/<placeholder>}}์˜ ํฌ๋งท์„ ์‚ฌ์šฉํ•˜์„ธ์š”. (์•”์‹œ์ ์ธ ๊ฒฝ๋กœ์ธ ๊ฒฝ์šฐ๋Š” ์ œ์™ธ!)
  • ๊ฒฝ๋กœ๊ฐ€ ์ƒ๋Œ€๊ฒฝ๋กœ์ผ ์ˆ˜ ์—†์ง€๋งŒ ํŒŒ์ผ ์‹œ์Šคํ…œ์˜ root์—์„œ ์‹œ์ž‘ํ•ด์•ผ ํ•˜๋Š” ๊ฒฝ์šฐ ์ ‘๋‘์‚ฌ๋กœ /๋ฅผ ๋ถ™์ž…๋‹ˆ๋‹ค. (ex: `get {{/path/to/remote_file
  • ํŒŒ์ผ ๋ฐ ๋””๋ ‰ํ† ๋ฆฌ ์ฐธ์กฐ๊ฐ€ ๋ชจ๋“œ ๊ฐ€๋Šฅํ•œ ๊ฒฝ์šฐ {{path/to/file_or_directory}}๋ฅผ ์‚ฌ์šฉํ•˜์„ธ์š”.

Extensions

  • ํŒŒ์ผ์— ํŠน์ • ํ™•์žฅ์ž๊ฐ€ ํ•„์š”ํ•œ ๊ฒฝ์šฐ ์ถ”๊ฐ€ํ•˜์‹ญ์‹œ์˜ค. (ex: unrar x {{compressed.rar}})
  • ๋งŒ์•ฝ ์ผ๋ฐ˜์ ์ธ ํ™•์žฅ์ž๊ฐ€ ํ•„์š”ํ•˜๋‹ค๋ฉด, ๋ฐ˜๋“œ์‹œ ํ•„์š”ํ•œ ๊ฒฝ์šฐ์—๋งŒ {{.ext}}๋ฅผ ์‚ฌ์šฉํ•˜์‹ญ์‹œ์˜ค. ์˜ˆ์‹œ1: find.md์˜ "ํ™•์žฅ์ž๋กœ ํŒŒ์ผ ์ฐพ๊ธฐ"(find {{root_path}} -name '{{*.ext}}')๋Š” {{*.ext}}๋ฅผ ์‚ฌ์šฉํ•˜์—ฌ ๋ถˆํ•„์š”ํ•œ ๋‚ด์šฉ ์—†์ด, ๊ตฌ์ฒด์ ์ด์ง€ ์•Š๊ฒŒ ์„ค๋ช…ํ•ฉ๋‹ˆ๋‹ค. ์˜ˆ์‹œ2: wc -l {{file}}๋Š” {{file}}์„ (extension ์—†์ด) ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ ๋งŒ์œผ๋กœ ์ถฉ๋ถ„ํ•ฉ๋‹ˆ๋‹ค.

Special Cases

  • ๋งŒ์•ฝ ๋ช…๋ น์–ด๊ฐ€ ํŒŒ์ผ ์‹œ์Šคํ…œ์ด๋‚˜ ์žฅ์น˜์— ๋Œ์ดํ‚ฌ ์ˆ˜ ์—†๋Š” ๋ณ€๊ฒฝ์„ ์ˆ˜ํ–‰ํ•˜๋Š” ๊ฒฝ์šฐ, ๋ชจ๋“  ์˜ˆ์ œ๋ฅผ ์ƒ๊ฐ ์—†์ด ๋ณต์‚ฌํ•˜์—ฌ ๋ถ™์—ฌ๋„ฃ์„ ์ˆ˜ ์—†๋„๋ก ์ž‘์„ฑํ•˜์‹ญ์‹œ์˜ค. ์˜ˆ๋ฅผ ๋“ค์–ด ddrescue --force --no-scrape /dev/sda /dev/sdb ๋Œ€์‹ ์— ddrescue --force --no-scrape {{/dev/sdX}} {{/dev/sdY}}๋ฅผ ์‚ฌ์šฉํ•˜๊ณ , *block device*์— /dev/sda1 ๋Œ€์‹  {{/dev/sdXY}} ์ž๋ฆฌ ํ‘œ์‹œ์ž๋ฅผ ์‚ฌ์šฉํ•˜์„ธ์š”.
  • ๋ช…๋ น์–ด๊ฐ€ ๋งŽ์€ ์ˆ˜์˜ ๋ช…๋ น์–ด๋ฅผ ํฌํ•จํ•  ์ˆ˜ ์žˆ๋Š” ๊ฒฝ์šฐ, ๋‹ค์Œ๊ณผ ๊ฐ™์ด ์ƒ๋žตํ•˜์—ฌ ํ‘œํ˜„ํ•˜์„ธ์š”. {{argument1 argument2 ...}} ์—ฌ๋Ÿฌ ์˜ต์…˜ ์ค‘ ํ•˜๋‚˜๊ฐ€ ๊ฐ€๋Šฅํ•œ ๊ฒฝ์šฐ {{either|or}}๋กœ ์ž‘์„ฑํ•ฉ๋‹ˆ๋‹ค.

์ผ๋ฐ˜์ ์œผ๋กœ, ํ† ํฐ์€ ๊ฐ€๋Šฅํ•œ ํ•œ ์ง๊ด€์ ์ด์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ๋ช…๋ น์„ ์‚ฌ์šฉํ•˜๋Š” ๋ฐฉ๋ฒ•์„ ํŒŒ์•…ํ•˜๊ณ  ๊ฐ’์œผ๋กœ ์ฑ„์šฐ์‹ญ์‹œ์˜ค.

๋‚ด์šฉ ์ž…๋ ฅ๋ž€์˜ ๊ธฐ์ˆ  ๋ฌธ๊ตฌ๋Š” backtick ๊ตฌ๋ฌธ์„ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ๋‹ค์Œ๊ณผ ๊ฐ™์ด ์—ญ๋”ฐ์˜ดํ‘œ๋ฅผ ์‚ฌ์šฉํ•˜์‹ญ์‹œ์˜ค.

  • Paths, ex. package.json, /etc/package.json.
  • Extensions, ex. .dll.
  • Commands, ex. ls.

Imperative Mood

์˜ˆ์‹œ ์„ค๋ช…ํ˜•์€ ๋ช…๋ น๋ฒ•์œผ๋กœ ํ‘œํ˜„๋˜์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์ž๋ฉด List all files.๋ฅผ Listing all files, File listing ๋“ฑ ์ž…๋‹ˆ๋‹ค. ์ด๊ฒƒ์€ ํŠน๋ณ„ํ•œ ๊ฒฝ์šฐ๋ฅผ ์ œ์™ธํ•˜๊ณ  ๊ธฐ๋ณธ์ ์œผ๋กœ ๋ชจ๋“  ๋ฒˆ์—ญ์— ์ ์šฉ๋ฉ๋‹ˆ๋‹ค.

Serial Comma

3๊ฐœ ์ด์ƒ์˜ ํ•ญ๋ชฉ ๋ชฉ๋ก์„ ์„ ์–ธํ•  ๋•Œ, Oxford ์‰ผํ‘œ๋ผ๊ณ ๋„ ๋ถ€๋ฅด๋Š” ์—ฐ์† ์‰ผํ‘œ๋ฅผ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค.

Git brances, tags, remotes๋ฅผ ์‚ญ์ œํ•˜์„ธ์š”.

์œ„์˜ ์˜ˆ๋Š” ์ง๋ ฌ ์‰ผํ‘œ๋ฅผ ์‚ฌ์šฉํ•˜์ง€ ์•Š์œผ๋ฏ€๋กœ ๋‹ค์Œ ๋‘ ๊ฐ€์ง€ ์ค‘ ํ•˜๋‚˜๋ฅผ ์˜๋ฏธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

  • tags์™€ remotes๋ผ๋Š” Git branch๋“ค์„ ์‚ญ์ œํ•˜์„ธ์š”.
  • Git branches, Git tag, Git remotes๋ฅผ ๋ชจ๋‘ ์‚ญ์ œํ•˜์„ธ์š”.

๋ชฉ๋ก์˜ ๋งˆ์ง€๋ง‰ ์š”์†Œ์—์„œ "and" ๋˜๋Š” "or" ์•ž์— ์‰ผํ‘œ๋ฅผ ์‚ฝ์ž…ํ•˜๋ฉด ์ด ๋ฌธ์ œ๋ฅผ ํ•ด๊ฒฐํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

Git branches, tags ๋ฐ remotes๋ฅผ ์‚ญ์ œํ•˜์„ธ์š”.

More information links

More information ์ค„์—๋Š” ์ž‘์„ฑ์ž๊ฐ€ ์ œ๊ณตํ•œ ๋ฌธ์„œ๋กœ ์—ฐ๊ฒฐํ•˜๋Š” ๊ฒƒ์„ ๊ถŒ์žฅํ•ฉ๋‹ˆ๋‹ค. ์‚ฌ์šฉํ•  ์ˆ˜ ์—†๋Š” ๊ฒฝ์šฐ, ๊ธฐ๋ณธ fallback์œผ๋กœ https://manned.org๋ฅผ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค.