You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Choose type "Computer Application" and give it some name.
21
-
* Download client credentials file.
22
-
*Copy it to `client_id.json` (name has to match) and save to `~/.md2googleslides`.
21
+
* Download client ID/secret file and shorten the name to: `client_id.json`.
22
+
*Move `client_id.json` (name has to be exact) to `~/.md2googleslides`.
23
23
24
24
After installing, import your slides by running:
25
25
26
+
```sh
27
+
md2gslides slides.md
28
+
```
29
+
30
+
You'll get a slide deck named "slides.md".
31
+
32
+
> NOTE: The first time you run the `md2gslides` command, you will be prompted for authorization. OAuth token credentials are stored in `~/.md2googleslides/credentials.json`. You may get a "scary-looking" screen that says, "Google hasn't verified this app." Click "Advanced" then "Go to _APP-NAME_ (unsafe)" if you trust yourself as the author of the app that's requesting to access your Slides files in Drive.
33
+
34
+
35
+
If you want to give the presentation a different name, use the `--title` option:
36
+
26
37
```sh
27
38
md2gslides slides.md --title "Talk Title"
28
39
```
29
40
30
41
This will generate new Google Slides in your account with title `Talk Title`.
31
42
32
-
NOTE: The first time the command is run you will be prompted for authorization. OAuth token
33
-
credentials are stored locally in a file named `~/.md2googleslides/credentials.json`.
43
+
Each time you run `md2gslides`, a new slide deck will be generated. If you want to append to or replace an existing slide deck, get the Drive file ID of that deck. The file ID is the 44-character string in a presentation's URL. For example, for this slide deck URL: `https://docs.google.com/presentation/d/1EAYk18WDjIG-zp_0vLm3CsfQh_i8eXc67Jo2O9C6Vuc/edit`, its file ID is `1EAYk18WDjIG-zp_0vLm3CsfQh_i8eXc67Jo2O9C6Vuc`.
44
+
45
+
Let's say you made some additional slides in `slides2.md`. To generate those slides and append to your existing deck, run:
46
+
47
+
```sh
48
+
md2gslides slides2.md --append FILE_ID
49
+
```
50
+
51
+
To regenerate and replace a deck you've created with file ID `FILE_ID`, run:
52
+
53
+
```sh
54
+
md2gslides slides.md --erase --append FILE_ID
55
+
```
34
56
35
-
Each time you will run the above comment, new slide deck will be generated. In order to work on exactly the same
36
-
deck, just get the ID of the already generated slides. For example, you can use following command:
57
+
Each time you run the `md2gslides` command, the newly-created or edited slide deck will open in a new browser tab. If you want to suppress that from happening because you already have it open in an existing tab, issue the `--no-browser` option. This command replaces an existing deck but doesn't open up a new browser tab:
If you're an advanced user, you can use the shorter alternative 1-character options:
64
+
65
+
```sh
66
+
md2gslides slides.md -nea FILE_ID -t "Talk Title"
41
67
```
42
68
69
+
70
+
Images (see syntax below) are expected to be online (have URLs), but if you have local files you wish you use the `--use-fileio` option. More info on this option down below in the [Local images](#local-images) section.
71
+
72
+
43
73
## Supported markdown rules
44
74
45
75
md2gslides uses a subset of the [CommonMark](http://spec.commonmark.org/0.26/) and
@@ -157,11 +187,7 @@ Even if you will use `--append` option for deck reuse, theme will be not changed
157
187
158
188
#### Inline images
159
189
160
-
Images can be placed on slides using image tags. Multiple images
161
-
can be included. Mulitple images in a single paragraph are arranged in columns,
162
-
mutiple paragraphs arranged as rows.
163
-
164
-
Note: Images are currently scaled and centered to fit the
190
+
Images can be placed on slides using image tags. Multiple images can be included. Mulitple images in a single paragraph are arranged in columns, multiple paragraphs arranged as rows. **NOTE:** Images are currently scaled and centered to fit the
165
191
slide template.
166
192
167
193
<pre>
@@ -322,6 +348,7 @@ console.log('Hello world');
322
348
```{style="font-size: 36pt"}
323
349
</pre>
324
350
351
+
325
352
### Tables
326
353
327
354
Tables are supported via
@@ -343,22 +370,18 @@ Dogs | 75 million
343
370
Birds | 16 million
344
371
</pre>
345
372
373
+
346
374
### Local images
347
375
348
-
Images referencing local paths temporarily uploaded and hosted to [file.io](https://file.io). File.io
349
-
is an emphemeral file serving service that generates short-lived random URLs to the upload file and deletes
350
-
content shortly after use.
376
+
Images referencing local paths temporarily uploaded and hosted to [file.io](https://file.io). File.io is an ephemeral file serving service that generates short-lived random URLs to the upload file and deletes content shortly after use.
351
377
352
-
Since local images are uploaded to a thrid party, explicit opt-in is required to use this feature.
353
-
Include the `--use-fileio` option to opt-in to uploading images. This applies to file-based images as well
378
+
Since local images are uploaded to a third party, explicit opt-in is required to use this feature. Include the `--use-fileio` option to opt-in to uploading images. This applies to file-based images as well
354
379
as automatically rasterized content like math expressions and SVGs.
355
380
381
+
356
382
### Image rasterization
357
383
358
-
Slides can also include generated images, using `$$$` fenced blocks
359
-
for the data. Currently supported generated images are math expression (TeX
360
-
and MathML) as well as SVG. Rasterized images are treated like local images are require
361
-
opt-in to uploading images to a 3rd party service via the `--use-fileio` option.
384
+
Slides can also include generated images, using `$$$` fenced blocks for the data. Currently supported generated images are math expression (TeX and MathML) as well as SVG. Rasterized images are treated like local images are require opt-in to uploading images to a 3rd party service via the `--use-fileio` option.
0 commit comments