Sort by - committed date
-
GitHub-flavored Markdown#Markdown Syntax As an extension, GitHub-flavored Markdown is also supported. This includes features such as strikethrough, tables, and task lists. Example Strikethrough In: ~~This text is strikethrough.~~ Out: This text is strikethrough. Task Lists In: - [x] Task 1 - [ ] Task 2 - [ ] Task 3 Out: Task 1 Task 2 Task 3
-
CommonMark specification#Markdown Syntax Scraps supports Markdown syntax according to the CommonMark specification. Please refer to the documentation of the pulldown-cmark library used internally for more details. CommonMark specification - pulldown-cmark guide Example In: # Heading 1 ## Heading 2 ### Heading 3 #### Heading 4 Out: Heading 1 Heading 2 Heading 3 Heading 4
-
Mermaid#Markdown Syntax By specifying mermaid as the language for a code block, you can use Mermaid diagrams. Example In: ```mermaid graph LR A --- B B-->C[fa:fa-ban forbidden] B-->D(fa:fa-spinner); ``` Out: graph LR A --- B B-->C[fa:fa-ban forbidden] B-->D(fa:fa-spinner);
-
Autolink#Markdown Syntax In Scraps, when you write using Markdown’s autolink syntax, it automatically fetches OGP data and displays it as a card. Example In: <https://github.com/boykush/scraps> Out: https://github.com/boykush/scraps
-
InstallationYou can find the latest version on GitHub Releases. Requirements The git command is required for features. Cargo ❯ cargo install scraps macOS ❯ brew install boykush/tap/scraps
-
ConfigurationConfiguration is managed by Config.toml in the Scraps project. Only the base_url and title variables are required. Everything else is optional. All configuration variables used by Scraps and their default values are listed below. # The site base url base_url = "https://username.github.io/repository-name/" # The site title title = "" # The site language (compliant with iso639-1, default=en) lang_code = "en" # The site description (optional) description = "" # The site favicon in the form of png file URL (optional) favicon = "" # The site timezone (optional, default=UTC) timezone = "UTC" # The site color scheme (optional, default=os_setting, choices=os_setting or only_light or only_dark) color_scheme = "os_setting" # Build a search index with the Fuse JSON and display search UI (optional, default=true, choices=true or false) build_search_index = true # Scraps sort key choice on index page (optional, default=committed_date, choices=committed_date or linked_count) sort_key = "committed_date" # Scraps pagination on index page (optional, default=no pagination) paginate_by = 20
-
CLI/Init#CLI ❯ scraps init your-scraps-project ❯ cd your-scraps-project This command initializes a new Scraps project. It creates the following structure: ❯ tree -a -L 1 . ├── .gitignore # Git ignore patterns for Scraps projects ├── Config.toml # Project configuration file └── scraps # Directory for your Markdown files After initializing the project, proceed to Build to generate your static site.
-
CLI/Build#CLI ❯ scraps build This command processes Markdown files from the /scraps directory and generates a static website. Source Structure ❯ tree scraps scraps ├── Getting Started.md └── What is Scraps?.md Generated Files The command generates the following files in the public directory: ❯ tree public public ├── index.html # Main page with scrap list ├── getting-started.html ├── what-is-scraps.html ├── main.css # Styling for the site └── search.json # Search index (if enabled) Each Markdown file is converted to a slugified HTML file. Additional files like index.html and main.css are generated to create a complete static website. After building, use Serve to preview your site locally.
-
CLI/Serve#CLI ❯ scraps serve This command starts a local development server to preview your static site. The server automatically serves the files from the public directory at http://127.0.0.1:1112. Use this command to check how your site looks and functions before deployment.
-
Language Server Protocol#Text Editor Currently, the most recommended LSP for editing Scraps is markdown-oxide. markdown-oxide supports the following editing environments: Neovim VSCode Zed Helix To match the current features provided by Scraps, place the following configuration file .moxide.toml under the scraps/ directory and open the scraps/ directory directly for a comfortable editing experience. heading_completions = false title_headings = false tags_in_codeblocks = false references_in_codeblocks = false We are considering a feature to generate the LSP configuration file during the init command.