Skip to content

Tips and Tricks

Dave Slusher edited this page Mar 7, 2018 · 10 revisions

How do I "Upload" the guidebook to SRC?

You don't actually upload it to SRC. Edit your presentation, commit it to Git then either "git push" or sync to get the changed document. Then you need to create a "Release" for each of the review rounds. Doing that communicates to SRC that the guidebook is ready.

  1. Navigate to the releases for your repository

    Releases page

  2. Create a new release

    Create a new release

  3. Fill out the information appropriately and publish that release

    Releases page

Markdownlint

To help with your Markdown formatting, install the markdownlint extension in VS Code. Click the square icon at the bottom of the left side to get to the extensions. Type "markdownlint" in the text box, and then click install. You will have to click "Reload" in order for your current window to get this. It will then show you places where you might have errors to look at. Hovering over the green squiggles will show what Markdownlint is complaining about.

Install Markdownlint

You probably want to turn off a few rules that our convention violates. Create a file named .markdownlint.json in the root of your project, the same level as your guidebook.md file. Inside the file add this:

{
    "MD013": false,
    "MD024": false,
    "MD025": false
}

Any rule can be turned on or off by adding it to this file with a value of "true" or "false".

Syncing

In order to move your changes to GitHub and/or pull them down, you will use the Git Sync function of VS Code. In the Source Control section (3rd icon from the top on the left hand side), click the three dot menu, then choose Sync.

Animated Gif of Sync

Converting from a Word Doc

If you have an existing Word document you can convert it with Pandoc.

  1. Install Pandoc
  2. Open your Terminal or Command window
  3. cd to the directory that holds your Word document
  4. Run: pandoc -f docx -t markdown --extract-media="." -o "name-of-your-output-md-file.md" "name-of-your-input-docx-file.docx"

Example: : pandoc -f docx -t markdown --extract-media="." -o "lab1234.md" "lab1234.docx" Expect to see all your document images under a folder named ‘media’ Edit ‘name-of-your-output-md-file.md’ in VS Code. (include the media folder in VS Code)

Adam Stout's Team Notes

[ Note - I removed a few that are already listed above - dhs ]

These are my notes I shared with my team:

Use VS Code

Recommended Extensions

Markdown Preview Enhanced - Yiyi Wang

Paste Image - mushan Should already be installed if you used the SN Self-Service

Code Spell Checker - Street Side Software

File Structure

  • Lab guide MUST BE NAMED "guidebook.md" and located in the root of your repo - this is required for the automation to work.
  • Recommended to not use "Lab #" as your headers since we then have labs in labs. Try "Exercise #"

Use Markdown Syntax

  • Code Blocks (start and end with ```)
```javascript
var groups = [];
var group = current.assignment_group;
while (group) {
    groups.push(group);
var gr = new GlideRecord('sys_user_group');
gr.get(group);
group = gr.getValue('parent');
}
groups;
```

Clone this wiki locally