Sort by - committed date
-
Reference/Tag#CLI ❯ scraps tag This command lists all tags found in your Scraps content, helping you understand the tag distribution across your knowledge base. Examples # List all tags ❯ scraps tag # List tags from specific directory ❯ scraps tag --path /path/to/project
-
Reference/Normal Link#Wiki-Links #Markdown Specifying the name of the markdown file with a notation such as [[Link]] will generate a wiki-like internal link. For example, if you have the following set of files. ❯ tree scraps scraps ├── Overview.md └── Usage.md Fill in the file name in the scraps directory in Overview.md as follows to generate the link. See [[Usage]] for detail.
-
Reference/Context Link#Wiki-Links #Markdown In cases where the same term exists in different contexts and Scrap titles would overlap, you can use the context feature by separating them with folders. For example: ❯ tree scraps scraps ├── DDD │ └── Service.md └── Kubernetes └── Service.md Links to Scrap with different contexts can be specified like [[DDD/Service]], [[Kubernetes/Service]]. You can also combine them with Alias link such as [[Kubernetes/Service|Kubernetes Service]]. The context is also displayed on the Scrap detail page in the static site. Not Recommended Scraps aims for simple knowledge management, so overuse of folders should be avoided. Use folders (Context) only in cases such as: When duplicate Scrap titles occur across different contexts When a Scrap has a strong association with a specific context
-
Reference/Search#CLI ❯ scraps search <QUERY> This command searches through your Scraps content using fuzzy matching to find relevant information across your knowledge base. Examples # Basic search ❯ scraps search "markdown" # Limit results to 10 ❯ scraps search "documentation" --num 10 The search uses fuzzy matching across file names, content, and Wiki-link references, displaying results ranked by relevance.
-
Reference/Alias Link#Wiki-Links #Markdown Internal links allow you to use different display text as aliases. Writing [[Markdown|here]] creates a link that displays as here but links to the “Markdown” page.
-
Reference/Init#CLI ❯ scraps init <PROJECT_NAME> 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 Examples # Initialize new project ❯ scraps init my-knowledge-base ❯ cd my-knowledge-base # Initialize with specific path ❯ scraps init docs --path /path/to/workspace After initializing the project, proceed to Build to generate your static site.
-
Reference/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. Examples # Basic serve ❯ scraps serve # Serve from specific directory ❯ scraps serve --path /path/to/project Use this command to check how your site looks and functions before deployment.
-
Reference/Configuration#Configuration Configuration is managed by Config.toml in the Scraps project. See Configure Project for a quick setup guide. Configuration Variables 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 scraps directory path relative to this Config.toml (optional, default=scraps) scraps_dir = "scraps" # 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