Skip to content

Commit a1e4cce

Browse files
author
David Cavazos
committed
Changed example.md to hello.md
1 parent a2bddc7 commit a1e4cce

File tree

3 files changed

+486
-0
lines changed

3 files changed

+486
-0
lines changed
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"metadata": {
6+
"id": "hello-world"
7+
},
8+
"source": [
9+
"# Hello World!\n",
10+
"\n",
11+
"This is a simple markdown page with GitHub code snippets.\n",
12+
"All this will be translated into a Jupyter notebook using the desired language."
13+
]
14+
},
15+
{
16+
"cell_type": "markdown",
17+
"metadata": {
18+
"id": "example"
19+
},
20+
"source": [
21+
"## Example\n",
22+
"\n",
23+
"Here is a code sample:"
24+
]
25+
},
26+
{
27+
"cell_type": "code",
28+
"execution_count": null,
29+
"metadata": {
30+
"id": "example-code"
31+
},
32+
"outputs": [],
33+
"source": [
34+
"# Hello world in Python.\n",
35+
"print('Hello from Python!')"
36+
]
37+
},
38+
{
39+
"cell_type": "markdown",
40+
"metadata": {
41+
"id": "example-2"
42+
},
43+
"source": [
44+
"</p><table>\n",
45+
" <td>\n",
46+
" <a target=\"_blank\" class=\"button\" href=\"https://colab.research.google.com/github//davidcavazos/md2ipynb/blob/master/examples/notebooks/hello-world-py.ipynb\">\n",
47+
" <img src=\"https://www.tensorflow.org/images/colab_logo_32px.png\" width=\"20px\" height=\"20px\"/>\n",
48+
" Run in Colab\n",
49+
" </a>\n",
50+
" </td>\n",
51+
" <td style=\"padding-left:1em\">\n",
52+
" <a target=\"_blank\" class=\"button\" href=\"https://github.com//davidcavazos/md2ipynb/blob/master/examples/code/hello-world.py\">\n",
53+
" <img src=\"https://www.tensorflow.org/images/GitHub-Mark-32px.png\" width=\"20px\" height=\"20px\"/>\n",
54+
" View on GitHub\n",
55+
" </a>\n",
56+
" </td>\n",
57+
"</table>\n",
58+
"<br/>\n",
59+
"\n",
60+
"You are all done!"
61+
]
62+
},
63+
{
64+
"cell_type": "markdown",
65+
"metadata": {
66+
"id": "html-section"
67+
},
68+
"source": [
69+
"## HTML Section\n",
70+
"\n",
71+
"<p>HTML is also supported since Markdown is a superset of HTML</p>"
72+
]
73+
},
74+
{
75+
"cell_type": "markdown",
76+
"metadata": {
77+
"id": "what-s-next"
78+
},
79+
"source": [
80+
"## What's next\n",
81+
"\n",
82+
"Check the [README.md](https://github.com/davidcavazos/md2ipynb/blob/master/README.md) for more instructions."
83+
]
84+
}
85+
],
86+
"metadata": {
87+
"colab": {
88+
"name": "Hello World!",
89+
"toc_visible": true
90+
},
91+
"kernelspec": {
92+
"display_name": "Python 3",
93+
"language": "python",
94+
"name": "python3"
95+
},
96+
"language_info": {
97+
"codemirror_mode": {
98+
"name": "ipython",
99+
"version": 3
100+
},
101+
"file_extension": ".py",
102+
"mimetype": "text/x-python",
103+
"name": "python",
104+
"nbconvert_exporter": "python",
105+
"pygments_lexer": "ipython3",
106+
"version": "3.7.3"
107+
}
108+
},
109+
"nbformat": 4,
110+
"nbformat_minor": 2
111+
}

examples/notebooks/hello.ipynb

Lines changed: 221 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,221 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"metadata": {
6+
"id": "view-in-github"
7+
},
8+
"source": [
9+
"<a href=\"https://colab.research.google.com/github/davidcavazos/md2ipynb/blob/master/examples/notebooks/hello.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open in Colab\"/></a>"
10+
]
11+
},
12+
{
13+
"cell_type": "markdown",
14+
"metadata": {
15+
"id": "view-the-docs-top"
16+
},
17+
"source": [
18+
"<table align=\"left\"><td><a target=\"_blank\" href=\"https://github.com/davidcavazos/md2ipynb\"><img src=\"https://www.tensorflow.org/images/GitHub-Mark-32px.png\" width=\"32\" height=\"32\" />View the Docs</a></td></table>"
19+
]
20+
},
21+
{
22+
"cell_type": "code",
23+
"execution_count": null,
24+
"metadata": {
25+
"cellView": "form",
26+
"id": "_-code"
27+
},
28+
"outputs": [],
29+
"source": [
30+
"#@title Licensed under the Apache License, Version 2.0 (the \"License\")\n",
31+
"# Licensed under the Apache License, Version 2.0 (the \"License\");\n",
32+
"# you may not use this file except in compliance with the License.\n",
33+
"# You may obtain a copy of the License at\n",
34+
"#\n",
35+
"# http://www.apache.org/licenses/LICENSE-2.0\n",
36+
"#\n",
37+
"# Unless required by applicable law or agreed to in writing, software\n",
38+
"# distributed under the License is distributed on an \"AS IS\" BASIS,\n",
39+
"# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n",
40+
"# See the License for the specific language governing permissions and\n",
41+
"# limitations under the License."
42+
]
43+
},
44+
{
45+
"cell_type": "markdown",
46+
"metadata": {
47+
"id": "hello-world"
48+
},
49+
"source": [
50+
"# Hello World!\n",
51+
"\n",
52+
"This is a simple markdown page with GitHub code snippets.\n",
53+
"All this will be translated into a Jupyter notebook using the desired language."
54+
]
55+
},
56+
{
57+
"cell_type": "markdown",
58+
"metadata": {
59+
"id": "setup"
60+
},
61+
"source": [
62+
"## Setup\n",
63+
"\n",
64+
"Create a virtual environment.\n",
65+
"\n",
66+
"Install the `md2ipynb` package."
67+
]
68+
},
69+
{
70+
"cell_type": "markdown",
71+
"metadata": {
72+
"id": "example"
73+
},
74+
"source": [
75+
"## Example\n",
76+
"\n",
77+
"Here is a code sample:"
78+
]
79+
},
80+
{
81+
"cell_type": "code",
82+
"execution_count": null,
83+
"metadata": {
84+
"id": "example-code"
85+
},
86+
"outputs": [],
87+
"source": [
88+
"# Hello world in Python.\n",
89+
"print('Hello from Python!')"
90+
]
91+
},
92+
{
93+
"cell_type": "markdown",
94+
"metadata": {
95+
"id": "example-2"
96+
},
97+
"source": [
98+
"</p><table>\n",
99+
" <td>\n",
100+
" <a target=\"_blank\" class=\"button\" href=\"https://colab.research.google.com/github//davidcavazos/md2ipynb/blob/master/examples/notebooks/example.ipynb\">\n",
101+
" <img src=\"https://www.tensorflow.org/images/colab_logo_32px.png\" width=\"20px\" height=\"20px\"/>\n",
102+
" Run in Colab\n",
103+
" </a>\n",
104+
" </td>\n",
105+
" <td style=\"padding-left:1em\">\n",
106+
" <a target=\"_blank\" class=\"button\" href=\"https://github.com//davidcavazos/md2ipynb/blob/master/examples/code/hello-world.py\">\n",
107+
" <img src=\"https://www.tensorflow.org/images/GitHub-Mark-32px.png\" width=\"20px\" height=\"20px\"/>\n",
108+
" View on GitHub\n",
109+
" </a>\n",
110+
" </td>\n",
111+
"</table>\n",
112+
"<br/>\n",
113+
"\n",
114+
"You are all done!"
115+
]
116+
},
117+
{
118+
"cell_type": "markdown",
119+
"metadata": {
120+
"id": "html-section"
121+
},
122+
"source": [
123+
"## HTML Section\n",
124+
"\n",
125+
"<p>HTML is also supported since Markdown is a superset of HTML</p>"
126+
]
127+
},
128+
{
129+
"cell_type": "markdown",
130+
"metadata": {
131+
"id": "form-view"
132+
},
133+
"source": [
134+
"## Form view\n",
135+
"\n",
136+
"In \"form view\", a code cell's contents will be hidden by default in\n",
137+
"[Colab](https://colab.research.google.com).\n",
138+
"You can open and close the contents by double clicking it."
139+
]
140+
},
141+
{
142+
"cell_type": "code",
143+
"execution_count": null,
144+
"metadata": {
145+
"cellView": "form",
146+
"id": "form-view-code"
147+
},
148+
"outputs": [],
149+
"source": [
150+
"#@title A code cell containing `#@title`\n",
151+
"# Contents will be hidden in Colab"
152+
]
153+
},
154+
{
155+
"cell_type": "markdown",
156+
"metadata": {
157+
"id": "form-view-2"
158+
},
159+
"source": [
160+
"Or, a code cell containing `#@param`."
161+
]
162+
},
163+
{
164+
"cell_type": "code",
165+
"execution_count": null,
166+
"metadata": {
167+
"cellView": "form",
168+
"id": "form-view-code-2"
169+
},
170+
"outputs": [],
171+
"source": [
172+
"message = \"Hello!\" #@param {type:\"string\"}\n",
173+
"\n",
174+
"print(f\"message: {repr(message)}\")"
175+
]
176+
},
177+
{
178+
"cell_type": "markdown",
179+
"metadata": {
180+
"id": "clean-up"
181+
},
182+
"source": [
183+
"## Clean up\n",
184+
"\n",
185+
"You're all done 🎉🎉"
186+
]
187+
},
188+
{
189+
"cell_type": "markdown",
190+
"metadata": {
191+
"id": "what-s-next"
192+
},
193+
"source": [
194+
"## What's next\n",
195+
"\n",
196+
"Check the [README.md](https://github.com/davidcavazos/md2ipynb/blob/master/README.md) for more instructions."
197+
]
198+
},
199+
{
200+
"cell_type": "markdown",
201+
"metadata": {
202+
"id": "view-the-docs-bottom"
203+
},
204+
"source": [
205+
"<table align=\"left\"><td><a target=\"_blank\" href=\"https://github.com/davidcavazos/md2ipynb\"><img src=\"https://www.tensorflow.org/images/GitHub-Mark-32px.png\" width=\"32\" height=\"32\" />View the Docs</a></td></table>"
206+
]
207+
}
208+
],
209+
"metadata": {
210+
"colab": {
211+
"name": "Hello md2ipynb!",
212+
"toc_visible": true
213+
},
214+
"kernelspec": {
215+
"display_name": "python3",
216+
"name": "python3"
217+
}
218+
},
219+
"nbformat": 4,
220+
"nbformat_minor": 2
221+
}

0 commit comments

Comments
 (0)