dotfiles

Personal dotfiles
git clone https://git.bracken.jp/dotfiles.git
Log | Files | Refs | LICENSE

config.toml (11509B)


      1 # This is the default config file.
      2 # It also shows all the default values, if you don't create the file.
      3 
      4 # All URL values may omit the scheme and/or port, as well as the beginning double slash
      5 # Valid URL examples:
      6 # gemini://example.com
      7 # //example.com
      8 # example.com
      9 # example.com:123
     10 
     11 
     12 [a-general]
     13 # Press Ctrl-H to access it
     14 home = "gemini://gemini.circumlunar.space"
     15 
     16 # Follow up to 5 Gemini redirects without prompting.
     17 # A prompt is always shown after the 5th redirect and for redirects to protocols other than Gemini.
     18 # If set to false, a prompt will be shown before following redirects.
     19 auto_redirect = false
     20 
     21 # What command to run to open a HTTP(S) URL.
     22 # Set to "default" to try to guess the browser, or set to "off" to not open HTTP(S) URLs.
     23 # If a command is set, than the URL will be added (in quotes) to the end of the command.
     24 # A space will be prepended to the URL.
     25 #
     26 # The best to define a command is using a string array.
     27 # Examples:
     28 # http = ['firefox']
     29 # http = ['custom-browser', '--flag', '--option=2']
     30 # http = ['/path/with spaces/in it/firefox']
     31 #
     32 # Note the use of single quotes, so that backslashes will not be escaped.
     33 # Using just a string will also work, but it is deprecated, and will degrade if
     34 # you use paths with spaces.
     35 
     36 http = 'default'
     37 
     38 # Any URL that will accept a query string can be put here
     39 search = "gemini://gus.guru/search"
     40 
     41 # Whether colors will be used in the terminal
     42 color = true
     43 
     44 # Whether ANSI color codes from the page content should be rendered
     45 ansi = true
     46 
     47 # Whether to replace list asterisks with unicode bullets
     48 bullets = true
     49 
     50 # Whether to show link after link text
     51 show_link = false
     52 
     53 # A number from 0 to 1, indicating what percentage of the terminal width the left margin should take up.
     54 left_margin = 0.15
     55 
     56 # The max number of columns to wrap a page's text to. Preformatted blocks are not wrapped.
     57 max_width = 100
     58 
     59 # 'downloads' is the path to a downloads folder.
     60 # An empty value means the code will find the default downloads folder for your system.
     61 # If the path does not exist it will be created.
     62 # Note the use of single quotes, so that backslashes will not be escaped.
     63 downloads = ''
     64 
     65 # Max size for displayable content in bytes - after that size a download window pops up
     66 page_max_size = 2097152  # 2 MiB
     67 # Max time it takes to load a page in seconds - after that a download window pops up
     68 page_max_time = 10
     69 
     70 # Whether to replace tab numbers with emoji favicons, which are cached.
     71 emoji_favicons = false
     72 
     73 # When a scrollbar appears. "never", "auto", and "always" are the only valid values.
     74 # "auto" means the scrollbar only appears when the page is longer than the window.
     75 scrollbar = "never"
     76 
     77 
     78 [auth]
     79 # Authentication settings
     80 # Note the use of single quotes for values, so that backslashes will not be escaped.
     81 
     82 [auth.certs]
     83 # Client certificates
     84 # Set domain name equal to path to client cert
     85 # "example.com" = 'mycert.crt'
     86 
     87 [auth.keys]
     88 # Client certificate keys
     89 # Set domain name equal to path to key for the client cert above
     90 # "example.com" = 'mycert.key'
     91 
     92 
     93 [keybindings]
     94 # If you have a non-US keyboard, use bind_tab1 through bind_tab0 to
     95 # setup the shift-number bindings: Eg, for US keyboards (the default):
     96 # bind_tab1 = "!"
     97 # bind_tab2 = "@"
     98 # bind_tab3 = "#"
     99 # bind_tab4 = "$"
    100 # bind_tab5 = "%"
    101 # bind_tab6 = "^"
    102 # bind_tab7 = "&"
    103 # bind_tab8 = "*"
    104 # bind_tab9 = "("
    105 # bind_tab0 = ")"
    106 
    107 # Whitespace is not allowed in any of the keybindings! Use 'Space' and 'Tab' to bind to those keys.
    108 # Multiple keys can be bound to one command, just use a TOML array.
    109 # To add the Alt modifier, the binding must start with Alt-, should be reasonably universal
    110 # Ctrl- won't work on all keys, see this for a list:
    111 # https://github.com/gdamore/tcell/blob/cb1e5d6fa606/key.go#L83
    112 
    113 # An example of a TOML array for multiple keys being bound to one command is the default
    114 # binding for reload:
    115 # bind_reload = ["R","Ctrl-R"]
    116 # One thing to note here is that "R" is capitalization sensitive, so it means shift-r.
    117 # "Ctrl-R" means both ctrl-r and ctrl-shift-R (this is a quirk of what ctrl-r means on
    118 # an ANSI terminal)
    119 
    120 # The default binding for opening the bottom bar for entering a URL or link number is:
    121 # bind_bottom = "Space"
    122 # This is how to get the Spacebar as a keybinding, if you try to use " ", it won't work.
    123 # And, finally, an example of a simple, unmodified character is:
    124 # bind_edit = "e"
    125 # This binds the "e" key to the command to edit the current URL.
    126 
    127 # The bind_link[1-90] options are for the commands to go to the first 10 links on a page,
    128 # typically these are bound to the number keys:
    129 # bind_link1 = "1"
    130 # bind_link2 = "2"
    131 # bind_link3 = "3"
    132 # bind_link4 = "4"
    133 # bind_link5 = "5"
    134 # bind_link6 = "6"
    135 # bind_link7 = "7"
    136 # bind_link8 = "8"
    137 # bind_link9 = "9"
    138 # bind_link0 = "0"
    139 
    140 # All keybindings:
    141 #
    142 # bind_bottom
    143 # bind_edit
    144 # bind_home
    145 # bind_bookmarks
    146 # bind_add_bookmark
    147 # bind_save
    148 # bind_reload
    149 # bind_back
    150 # bind_forward
    151 # bind_pgup
    152 # bind_pgdn
    153 # bind_new_tab
    154 # bind_close_tab
    155 # bind_next_tab
    156 # bind_prev_tab
    157 # bind_quit
    158 # bind_help
    159 # bind_sub: for viewing the subscriptions page
    160 # bind_add_sub
    161 
    162 [url-handlers]
    163 # Allows setting the commands to run for various URL schemes.
    164 # E.g. to open FTP URLs with FileZilla set the following key:
    165 #   ftp = 'filezilla'
    166 # You can set any scheme to "off" or "" to disable handling it, or
    167 # just leave the key unset.
    168 #
    169 # DO NOT use this for setting the HTTP command.
    170 # Use the http setting in the "a-general" section above.
    171 #
    172 # NOTE: These settings are overrided by the ones in the proxies section.
    173 # Note the use of single quotes, so that backslashes will not be escaped.
    174 
    175 # This is a special key that defines the handler for all URL schemes for which
    176 # no handler is defined.
    177 other = 'off'
    178 
    179 
    180 # [[mediatype-handlers]] section
    181 # ---------------------------------
    182 #
    183 # Specify what applications will open certain media types.
    184 # By default your default application will be used to open the file when you select "Open".
    185 # You only need to configure this section if you want to override your default application,
    186 # or do special things like streaming.
    187 #
    188 # Note the use of single quotes for commands, so that backslashes will not be escaped.
    189 #
    190 #
    191 # To open jpeg files with the feh command:
    192 #
    193 # [[mediatype-handlers]]
    194 # cmd = ['feh']
    195 # types = ["image/jpeg"]
    196 #
    197 # Each command that you specify must come under its own [[mediatype-handlers]]. You may
    198 # specify as many [[mediatype-handlers]] as you want to setup multiple commands.
    199 #
    200 # If the subtype is omitted then the specified command will be used for the
    201 # entire type:
    202 #
    203 # [[mediatype-handlers]]
    204 # command = ['vlc', '--flag']
    205 # types = ["audio", "video"]
    206 #
    207 # A catch-all handler can by specified with "*".
    208 # Note that there are already catch-all handlers in place for all OSes,
    209 # that open the file using your default application. This is only if you
    210 # want to override that.
    211 #
    212 # [[mediatype-handlers]]
    213 # cmd = ['some-command']
    214 # types = [
    215 #         "application/pdf",
    216 #         "*",
    217 # ]
    218 #
    219 # You can also choose to stream the data instead of downloading it all before
    220 # opening it. This is especially useful for large video or audio files, as
    221 # well as radio streams, which will never complete. You can do this like so:
    222 #
    223 # [[mediatype-handlers]]
    224 # cmd = ['vlc', '-']
    225 # types = ["audio", "video"]
    226 # stream = true
    227 #
    228 # This uses vlc to stream all video and audio content.
    229 # By default stream is set to off for all handlers
    230 #
    231 #
    232 # If you want to always open a type in its viewer without the download or open
    233 # prompt appearing, you can add no_prompt = true
    234 #
    235 # [[mediatype-handlers]]
    236 # cmd = ['feh']
    237 # types = ["image"]
    238 # no_prompt = true
    239 #
    240 # Note: Multiple handlers cannot be defined for the same full media type, but
    241 # still there needs to be an order for which handlers are used. The following
    242 # order applies regardless of the order written in the config:
    243 #
    244 # 1. Full media type: "image/jpeg"
    245 # 2. Just type: "image"
    246 # 3. Catch-all: "*"
    247 
    248 
    249 [cache]
    250 # Options for page cache - which is only for text pages
    251 # Increase the cache size to speed up browsing at the expense of memory
    252 # Zero values mean there is no limit
    253 
    254 max_size = 0  # Size in bytes
    255 max_pages = 30 # The maximum number of pages the cache will store
    256 
    257 # How long a page will stay in cache, in seconds.
    258 timeout = 1800 # 30 mins
    259 
    260 [proxies]
    261 # Allows setting a Gemini proxy for different schemes.
    262 # The settings are similar to the url-handlers section above.
    263 # E.g. to open a gopher page by connecting to a Gemini proxy server:
    264 #   gopher = "example.com:123"
    265 #
    266 # Port 1965 is assumed if no port is specified.
    267 #
    268 # NOTE: These settings override any external handlers specified in
    269 # the url-handlers section.
    270 #
    271 # Note that HTTP and HTTPS are treated as separate protocols here.
    272 
    273 
    274 [subscriptions]
    275 # For tracking feeds and pages
    276 
    277 # Whether a pop-up appears when viewing a potential feed
    278 popup = true
    279 
    280 # How often to check for updates to subscriptions in the background, in seconds.
    281 # Set it to 0 to disable this feature. You can still update individual feeds
    282 # manually, or restart the browser.
    283 #
    284 # Note Amfora will check for updates on browser start no matter what this setting is.
    285 update_interval = 1800 # 30 mins
    286 
    287 # How many subscriptions can be checked at the same time when updating.
    288 # If you have many subscriptions you may want to increase this for faster
    289 # update times. Any value below 1 will be corrected to 1.
    290 workers = 3
    291 
    292 # The number of subscription updates displayed per page.
    293 entries_per_page = 20
    294 
    295 
    296 [theme]
    297 # This section is for changing the COLORS used in Amfora.
    298 # These colors only apply if 'color' is enabled above.
    299 # Colors can be set using a W3C color name, or a hex value such as "#ffffff".
    300 
    301 # Note that not all colors will work on terminals that do not have truecolor support.
    302 # If you want to stick to the standard 16 or 256 colors, you can get
    303 # a list of those here: https://jonasjacek.github.io/colors/
    304 # DO NOT use the names from that site, just the hex codes.
    305 
    306 # Definitions:
    307 #   bg = background
    308 #   fg = foreground
    309 #   dl = download
    310 #   btn = button
    311 #   hdg = heading
    312 #   bkmk = bookmark
    313 #   modal = a popup window/box in the middle of the screen
    314 
    315 # EXAMPLES:
    316 # hdg_1 = "green"
    317 # hdg_2 = "#5f0000"
    318 
    319 # Available keys to set:
    320 
    321 # bg: background for pages, tab row, app in general
    322 # tab_num: The number/highlight of the tabs at the top
    323 # tab_divider: The color of the divider character between tab numbers: |
    324 # bottombar_label: The color of the prompt that appears when you press space
    325 # bottombar_text: The color of the text you type
    326 # bottombar_bg
    327 # scrollbar: The scrollbar that appears on the right for long pages
    328 
    329 # hdg_1
    330 # hdg_2
    331 # hdg_3
    332 # amfora_link: A link that Amfora supports viewing. For now this is only gemini://
    333 # foreign_link: HTTP(S), Gopher, etc
    334 # link_number: The silver number that appears to the left of a link
    335 # regular_text: Normal gemini text, and plaintext documents
    336 # quote_text
    337 # preformatted_text
    338 # list_text
    339 
    340 # btn_bg: The bg color for all modal buttons
    341 # btn_text: The text color for all modal buttons
    342 
    343 # dl_choice_modal_bg
    344 # dl_choice_modal_text
    345 # dl_modal_bg
    346 # dl_modal_text
    347 # info_modal_bg
    348 # info_modal_text
    349 # error_modal_bg
    350 # error_modal_text
    351 # yesno_modal_bg
    352 # yesno_modal_text
    353 # tofu_modal_bg
    354 # tofu_modal_text
    355 # subscription_modal_bg
    356 # subscription_modal_text
    357 
    358 # input_modal_bg
    359 # input_modal_text
    360 # input_modal_field_bg: The bg of the input field, where you type the text
    361 # input_modal_field_text: The color of the text you type
    362 
    363 # bkmk_modal_bg
    364 # bkmk_modal_text
    365 # bkmk_modal_label
    366 # bkmk_modal_field_bg
    367 # bkmk_modal_field_text