tldr/pages/common/carbon-now.md

37 lines
879 B
Markdown
Raw Normal View History

2020-09-05 12:40:30 +01:00
# carbon-now
> Create beautiful images of code.
2021-01-07 18:07:46 +00:00
> More information: <https://github.com/mixn/carbon-now-cli>.
2020-09-05 12:40:30 +01:00
- Create an image from a file using default settings:
2022-12-04 09:12:49 +00:00
`carbon-now {{path/to/file}}`
2020-09-05 12:40:30 +01:00
- Create an image from a text in clipboard using default settings:
`carbon-now --from-clipboard`
- Create an image from `stdin` using default settings and copy to the clipboard:
2020-09-05 12:40:30 +01:00
`{{input}} | carbon-now --to-clipboard`
2020-09-05 12:40:30 +01:00
- Create images [i]nteractively for custom settings and optionally save a preset:
2020-09-05 12:40:30 +01:00
2022-12-04 09:12:49 +00:00
`carbon-now -i {{path/to/file}}`
2020-09-05 12:40:30 +01:00
- Create images from a previously saved [p]reset:
2020-09-05 12:40:30 +01:00
2022-12-04 09:12:49 +00:00
`carbon-now -p {{preset}} {{path/to/file}}`
2020-09-05 12:40:30 +01:00
- [s]tart at a specified line of text:
2020-09-05 12:40:30 +01:00
2022-12-04 09:12:49 +00:00
`carbon-now -s {{line}} {{path/to/file}}`
2020-09-05 12:40:30 +01:00
- [e]nd at a specific line of text:
2020-09-05 12:40:30 +01:00
2022-12-04 09:12:49 +00:00
`carbon-now -e {{line}} {{path/to/file}}`
2020-09-05 12:40:30 +01:00
- Open image in a browser instead of saving:
2022-12-04 09:12:49 +00:00
`carbon-now --open {{path/to/file}}`