From c9d687d6fed8ee9d0b9dfd1ebb55ddbb30b39fe2 Mon Sep 17 00:00:00 2001 From: Jarka Kadlecova Date: Mon, 6 Feb 2017 16:04:00 +0100 Subject: Download snippets with LF line-endings by default --- doc/user/snippets.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 doc/user/snippets.md (limited to 'doc/user/snippets.md') diff --git a/doc/user/snippets.md b/doc/user/snippets.md new file mode 100644 index 00000000000..417360e08ac --- /dev/null +++ b/doc/user/snippets.md @@ -0,0 +1,19 @@ +# Snippets + +Snippets are little bits of code or text. + +There are 2 types of snippets - project snippets and personal snippets. + +## Project snippets + +Project snippets are always related to a specific project - see [Project features](../workflow/project_features.md) for more information. + +## Personal snippets + +Personal snippets are not related to any project and can be created completely independently. There are 3 visibility levels that can be set (public, internal, private - see [Public Access](../public_access/public_access.md) for more information). + +## Downloading snippets + +You can download the raw content of a snippet. + +By default snippets will be downloaded with Linux-style line endings (`LF`). If you want to preserve the original line endings you need to add a parameter `line_ending=raw` (eg. `https://gitlab.com/snippets/SNIPPET_ID/raw?line_ending=raw`). In case a snippet was created using the GitLab web interface the original line ending is Windows-like (`CRLF`). -- cgit v1.2.1