Super ScreenShot is a set of libraries and tools for building screenshots in a standardized, high-performance image format made in rust.
It provides different options depending on your needs.
- sss_lib: The base library for screenshot generation, providing the core functionality for the other tools.
- sss_code: A terminal tool specifically designed to take screenshots of your code, making it easy to share and showcase your snippets.
- sss: A versatile terminal tool that allows you to capture screenshots of your entire screen or specific regions.
Important
At the moment the tool is not available in any store. Please redirect to releases section in order to download.
sss packages are built and cached automatically. To avoid unnecessary recompilations, you may use the binary cache.
nix.settings = {
builders-use-substitutes = true;
extra-substituters = [ "https://sss.cachix.org" ];
extra-trusted-public-keys = [ "sss.cachix.org-1:YI2JMG95LEu62PC7VMz75N7bypEdUz9Z/Il1hkGH4AA=" ];
};
Warning
While using the sss flake, overriding the nixpkgs input for sss will cause cache hits, i.e., you will have to build from source every time. To use the cache, do not override the Nixpkgs input.
On nix you can use the provided flake:
# flake.nix
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
sss = {
url = "github:SergioRibera/sss";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs }: {
nixosConfigurations."<your_hostname>" = nixpkgs.lib.nixosSystem {
# ...
modules = [
# Add sss to modules to make it available
inputs.sss.nixosModules.default
{
programs.sss {
enable = true; # Enable principal cli to take screenshots
code = true; # Enable sss_code to capture code
}
}
];
# ...
};
};
}
[!INFO] You can find more details about the available options at here
home-manager.users."yourusername" = ({
imports = [
inputs.sss.nixosModules.home-manager
];
programs.sss = {
enable = true;
code = {
enable = true;
line-numbers = true;
};
general = {
shadow = true;
shadow-image = true;
author = "@SergioRibera";
colors = {
background = "#FFFFFF";
author = "#000000";
};
};
};
};
Note
To know how to configure it from a file, you can review the default.toml file.
All cli arguments can be set from a single file in the path ~/.config/sss/config.toml
, right here you can place the configuration for sss_code
and sss
.
You can find examples and options in the following links.
- syntect: Rust library for syntax highlighting using Sublime Text syntax definitions.
- I use this library for code highlighting and parsing.
- djanho: Convert VSCode themes to (Neo)Vim colorschemes
- Use this project to understand how to import (Neo)vim themes.
- silicon: Create beautiful image of your source code.
- I used it as a basis for my code screenshot project.