Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add syntax highlighting to the code snippets on the website #1

Open
3 tasks
thibaudcolas opened this issue Oct 2, 2018 · 5 comments
Open
3 tasks
Labels
good first issue Good for newcomers hacktoberfest https://hacktoberfest.digitalocean.com/ help wanted Extra attention is needed

Comments

@thibaudcolas
Copy link
Contributor

thibaudcolas commented Oct 2, 2018

https://ouluwebdev.github.io/hello-hacktoberfest/ displays all Hello, World! snippets, but it doesn't have syntax highlighting. We need to add that!

It should:

@thibaudcolas thibaudcolas added help wanted Extra attention is needed good first issue Good for newcomers hacktoberfest https://hacktoberfest.digitalocean.com/ labels Oct 2, 2018
@kwaimind
Copy link

kwaimind commented Oct 2, 2018

I can take a swing at this. Can you assign the task to me?

@thibaudcolas
Copy link
Contributor Author

@kwaimind sure! Let me know if I can help.

@thibaudcolas
Copy link
Contributor Author

Actually GitHub only allows to assign people who have contributed at least once. But consider it yours!

@kwaimind
Copy link

kwaimind commented Oct 2, 2018

Added prism but having an issue getting the right syntax to show. Working on it.

@kwaimind
Copy link

kwaimind commented Oct 5, 2018

Hey @thibaudcolas I submitted a pull request a few days ago. Are you still interested in this feature?

jtiala added a commit that referenced this issue Oct 24, 2018
Totally not copied from esolang wiki. For reference,

```
 1 +++++ +++               Set Cell #0 to 8
 2 [
 3     >++++               Add 4 to Cell #1; this will always set Cell #1 to 4
 4     [                   as the cell will be cleared by the loop
 5         >++             Add 4*2 to Cell #2
 6         >+++            Add 4*3 to Cell #3
 7         >+++            Add 4*3 to Cell #4
 8         >+              Add 4 to Cell #5
 9         <<<<-           Decrement the loop counter in Cell #1
10     ]                   Loop till Cell #1 is zero
11     >+                  Add 1 to Cell #2
12     >+                  Add 1 to Cell #3
13     >-                  Subtract 1 from Cell #4
14     >>+                 Add 1 to Cell #6
15     [<]                 Move back to the first zero cell you find; this will
16                         be Cell #1 which was cleared by the previous loop
17     <-                  Decrement the loop Counter in Cell #0
18 ]                       Loop till Cell #0 is zero
19 
20 The result of this is:
21 Cell No :   0   1   2   3   4   5   6
22 Contents:   0   0  72 104  88  32   8
23 Pointer :   ^
24 
25 >>.                     Cell #2 has value 72 which is 'H'
26 >---.                   Subtract 3 from Cell #3 to get 101 which is 'e'
27 +++++ ++..+++.          Likewise for 'llo' from Cell #3
28 >>.                     Cell #5 is 32 for the space
29 <-.                     Subtract 1 from Cell #4 for 87 to give a 'W'
30 <.                      Cell #3 was set to 'o' from the end of 'Hello'
31 +++.----- -.----- ---.  Cell #3 for 'rl' and 'd'
32 >>+.                    Add 1 to Cell #5 gives us an exclamation point
33 >++.                    And finally a newline from Cell #6
```
thibaudcolas pushed a commit that referenced this issue Oct 24, 2018
Totally not copied from esolang wiki. For reference,

```
 1 +++++ +++               Set Cell #0 to 8
 2 [
 3     >++++               Add 4 to Cell #1; this will always set Cell #1 to 4
 4     [                   as the cell will be cleared by the loop
 5         >++             Add 4*2 to Cell #2
 6         >+++            Add 4*3 to Cell #3
 7         >+++            Add 4*3 to Cell #4
 8         >+              Add 4 to Cell #5
 9         <<<<-           Decrement the loop counter in Cell #1
10     ]                   Loop till Cell #1 is zero
11     >+                  Add 1 to Cell #2
12     >+                  Add 1 to Cell #3
13     >-                  Subtract 1 from Cell #4
14     >>+                 Add 1 to Cell #6
15     [<]                 Move back to the first zero cell you find; this will
16                         be Cell #1 which was cleared by the previous loop
17     <-                  Decrement the loop Counter in Cell #0
18 ]                       Loop till Cell #0 is zero
19 
20 The result of this is:
21 Cell No :   0   1   2   3   4   5   6
22 Contents:   0   0  72 104  88  32   8
23 Pointer :   ^
24 
25 >>.                     Cell #2 has value 72 which is 'H'
26 >---.                   Subtract 3 from Cell #3 to get 101 which is 'e'
27 +++++ ++..+++.          Likewise for 'llo' from Cell #3
28 >>.                     Cell #5 is 32 for the space
29 <-.                     Subtract 1 from Cell #4 for 87 to give a 'W'
30 <.                      Cell #3 was set to 'o' from the end of 'Hello'
31 +++.----- -.----- ---.  Cell #3 for 'rl' and 'd'
32 >>+.                    Add 1 to Cell #5 gives us an exclamation point
33 >++.                    And finally a newline from Cell #6
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers hacktoberfest https://hacktoberfest.digitalocean.com/ help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants