Skip to content

Commit 4dbbe18

Browse files
author
Jordan McCullough
committed
Merge pull request #99 from github/workbook-tune-up
Remove all `<a>` in Workbook Markdown
2 parents f7f9751 + 1df0d5b commit 4dbbe18

File tree

6 files changed

+63
-49
lines changed

6 files changed

+63
-49
lines changed

_layouts/workbook.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ <h2>{{ page.title }}</h2>
1212
</div>
1313
</section>
1414

15-
<section>
15+
<section class="workbook">
1616
<div class="container">
1717

1818
<div class="tab-panel">

_stylesheets/workbook.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

_stylesheets/workbook.scss

Lines changed: 41 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,47 @@
55
display: none;
66
}
77

8+
9+
@mixin octicon-link($char){
10+
font: normal normal 1em octicons;
11+
text-decoration: none;
12+
color: $color-dark;
13+
14+
&:before{
15+
content: $char;
16+
margin-right: 5px;
17+
}
18+
}
19+
20+
.workbook{
21+
/* General external link */
22+
a[href^="http://"] {
23+
@include octicon-link("\f0b6");
24+
}
25+
26+
/* GitHub Links */
27+
a[href^="https://github.com"],
28+
a[href^="https://www.github.com"],
29+
a[href^="https://help.github.com"]
30+
{
31+
@include octicon-link("\f008");
32+
}
33+
34+
/* GitHub Book Links, Guide Links */
35+
a[href^="http://git-scm.com/book"],
36+
a[href^="https://guides.github.com"]
37+
{
38+
@include octicon-link("\f007");
39+
}
40+
41+
42+
/* YouTube Links */
43+
a[href^="https://youtube.com"],
44+
a[href^="https://www.youtube.com"] {
45+
@include octicon-link("\f0b9");
46+
}
47+
}
48+
849
/* Scopes wrapper */
950

1051
.outline{
@@ -108,33 +149,6 @@
108149
}
109150
}
110151

111-
.booklink{
112-
&:before{
113-
content: "\f007";
114-
margin-right: 5px;
115-
}
116-
}
117-
118-
.githublink{
119-
&:before{
120-
content: "\f008";
121-
margin-right: 5px;
122-
}
123-
}
124-
125-
.weblink{
126-
&:before{
127-
content: "\f0b6";
128-
margin-right: 5px;
129-
}
130-
}
131-
132-
.videolink{
133-
&:before{
134-
content: "\f0b9";
135-
margin-right: 5px;
136-
}
137-
}
138152

139153

140154
.summary, .outline, .details{

workbooks/github-advanced.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -239,8 +239,8 @@ $ git commit --amend
239239
## Advanced GitHub Issues
240240

241241
### Summary
242-
* <a href="https://guides.github.com/overviews/issues/" class="githublink">Guide to Mastering Issues</a>
243-
* <a href="https://help.github.com/articles/closing-issues-via-commit-messages" class="githublink">Automatic closing of Issues by commit</a>
242+
* [Guide to Mastering Issues](https://guides.github.com/overviews/issues/)
243+
* [Automatic closing of Issues by commit](https://help.github.com/articles/closing-issues-via-commit-messages)
244244
* Symmetric cross-links of issue mentions
245245
* Cross-repo Issue mentions
246246

@@ -429,8 +429,8 @@ $ git rebase -i [remote]/[branch]
429429
## Advanced rebasing
430430

431431
### Summary
432-
* <a href="http://git-scm.com/book/ch3-6.html" class="booklink">Rebasing chapter of Pro Git book</a>
433-
* <a href="http://git-scm.com/book/ch3-6.html#More-Interesting-Rebases" class="booklink">Git rebase --onto section of Pro Git book</a>
432+
* [Rebasing chapter of Pro Git book](http://git-scm.com/book/ch3-6.html)
433+
* [Git rebase --onto section of Pro Git book](http://git-scm.com/book/ch3-6.html#More-Interesting-Rebases)
434434
* Changing where branch history begins
435435
* Moving blocks of history around
436436
* Breadcrumbs for later fixups and squashes
@@ -605,9 +605,9 @@ $ git credential-cache exit
605605
* Classic authentication with GitHub
606606
* Diminishing in use at HTTPS increases
607607
* Blocked by more firewalls
608-
* <a href="https://help.github.com/articles/generating-ssh-keys" class="booklink">Generate SSH key</a>
609-
* <a href="https://github.com/settings/ssh" class="githublink">Upload public key to GitHub</a>
610-
* <a href="https://github.com/settings/ssh" class="githublink">Audit SSH key use</a>
608+
* [Generate SSH key](https://help.github.com/articles/generating-ssh-keys)
609+
* [Upload public key to GitHub](https://github.com/settings/ssh)
610+
* [Audit SSH key use](https://github.com/settings/ssh)
611611

612612

613613
#### Details
@@ -637,9 +637,9 @@ $ gitk --all
637637
## Widely used GUIs
638638

639639
### Summary
640-
* <a href="http://git-scm.com/downloads/guis" class="weblink">Listing of GUIs</a>
641-
* <a href="http://eclipse.github.com" class="weblink">eGit for Eclipse</a>
642-
* <a href="http://www.syntevo.com/smartgithg/" class="weblink">SmartGit for Windows, Mac, Linux</a>
640+
* [Listing of GUIs](http://git-scm.com/downloads/guis)
641+
* [eGit for Eclipse](http://eclipse.github.com)
642+
* [SmartGit for Windows, Mac, Linux](http://www.syntevo.com/smartgithg/)
643643

644644
## Refspecs
645645
### Summary

workbooks/github-foundations.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ description: This student and teacher workbook will be your companion to the Git
1212
* Git, the information tracker
1313
* GitHub, the collaboration platform
1414
* Distributed version control
15-
* <a href="http://git-scm.com/book/en/Getting-Started-A-Short-History-of-Git" class="booklink">A short history of Git</a>
16-
* <a href="http://git-scm.com" class="weblink">The Git project homepage</a>
15+
* [A short history of Git](http://git-scm.com/book/en/Getting-Started-A-Short-History-of-Git)
16+
* [The Git project homepage](http://git-scm.com)
1717

1818
#### Details
1919
__Git is an open source distributed__ version control system invented by Linus Torvalds in 2005. It is used to version the Linux kernel and is shown to be, by some research, the most popular modern version control system.
@@ -31,9 +31,9 @@ git version 1.8.2
3131
```
3232

3333
## GitHub Installers
34-
* <a href="http://windows.github.com" class="weblink">GitHub for Windows installer</a>
35-
* <a href="http://mac.github.com" class="weblink">GitHub for Mac installer</a>
36-
* <a href="http://git-scm.com/book/en/Getting-Started-Installing-Git" class="booklink">Pro Git Book: Installing Git</a>
34+
* [GitHub for Windows installer](http://windows.github.com)
35+
* [GitHub for Mac installer](http://mac.github.com)
36+
* [Pro Git Book: Installing Git](http://git-scm.com/book/en/Getting-Started-Installing-Git)
3737
* **Windows**: The GitHub for Windows installer can be found at http://windows.github.com.
3838
* **Mac**: The GitHub for Mac installer can be found at http://mac.github.com.
3939
* **Linux**: Git's source code and a listing of supported package managers can be found at http://git-scm.com/download/linux.
@@ -43,8 +43,8 @@ The command line version of Git has a very light footprint. For most platforms,
4343

4444

4545
## The GitHub platform
46-
* <a href="https://github.com/features" class="githublink">GitHub.com feature list</a>
47-
* <a href="https://www.youtube.com/watch?v=ezxRcdJ8glM&list=PLg7s6cbtAD17rhrz2BJWAPJMjR71B3IDx" class="videolink">How to sign up for GitHub</a>
46+
* [GitHub.com feature list](https://github.com/features)
47+
* [How to sign up for GitHub](https://www.youtube.com/watch?v=ezxRcdJ8glM&list=PLg7s6cbtAD17rhrz2BJWAPJMjR71B3IDx)
4848

4949
### Details
5050
GitHub accounts are free. Sign up for one at [github.com/join](https://github.com/join).
@@ -61,7 +61,7 @@ Git can be installed as a unified GitHub GUI and command line or merely as a sta
6161
## Ways of interacting with repositories
6262

6363
### Summary
64-
* <a href="https://guides.github.com/overviews/flow/" class="booklink">GitHub web flow</a>
64+
* [GitHub web flow](https://guides.github.com/overviews/flow/)
6565
* GitHub GUIs for Mac, Windows
6666
* Command line
6767

@@ -106,7 +106,7 @@ Git can be installed as a unified GitHub GUI and command line or merely as a sta
106106

107107
### Summary
108108
* Forking
109-
* <a href="https://guides.github.com/overviews/forking/" class="booklink">Guide to Forking</a>
109+
* [Guide to Forking](https://guides.github.com/overviews/forking/)
110110
* Reason for forks
111111
* What it encourages
112112
* How it insulates

workbooks/github-intermediate.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ $ git config --global color.ui auto
3232

3333
## Configuing the Git User
3434
### Summary
35-
* <a href="http://git-scm.com/book/en/Getting-Started-First-Time-Git-Setup" class="booklink">Pro Git Book: First Time Git Setup</a>
35+
* [Pro Git Book: First Time Git Setup](http://git-scm.com/book/en/Getting-Started-First-Time-Git-Setup)
3636
* Username
3737
* Email address
3838
* No password

0 commit comments

Comments
 (0)