{"id":17494377,"url":"https://github.com/lkubb/salt-tool-asdf-formula","last_synced_at":"2026-04-28T11:33:56.733Z","repository":{"id":50447807,"uuid":"483867383","full_name":"lkubb/salt-tool-asdf-formula","owner":"lkubb","description":"Manage packages and their versions with asdf and Salt. Provides an execution/state module for Salt.","archived":false,"fork":false,"pushed_at":"2024-11-29T18:00:53.000Z","size":325,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-28T18:18:55.709Z","etag":null,"topics":["asdf","development-environment","devops","salt-formula","saltstack"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lkubb.png","metadata":{"files":{"readme":"docs/README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-21T01:30:39.000Z","updated_at":"2024-11-29T18:00:58.000Z","dependencies_parsed_at":"2024-11-09T18:26:17.828Z","dependency_job_id":"a1b766e4-9791-4255-a553-a7485389d280","html_url":"https://github.com/lkubb/salt-tool-asdf-formula","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lkubb/salt-tool-asdf-formula","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-tool-asdf-formula","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-tool-asdf-formula/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-tool-asdf-formula/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-tool-asdf-formula/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lkubb","download_url":"https://codeload.github.com/lkubb/salt-tool-asdf-formula/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-tool-asdf-formula/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32379342,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-28T11:25:28.583Z","status":"ssl_error","status_checked_at":"2026-04-28T11:25:05.435Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["asdf","development-environment","devops","salt-formula","saltstack"],"created_at":"2024-10-19T13:06:20.027Z","updated_at":"2026-04-28T11:33:56.708Z","avatar_url":"https://github.com/lkubb.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":".. _readme:\n\nasdf Formula\n============\n\nManages asdf and some selected tools for development environments in the user environment.\n\n.. contents:: **Table of Contents**\n   :depth: 1\n\nUsage\n-----\nApplying ``tool_asdf`` will make sure ``asdf`` and its managed packages are configured as specified.\n\nExecution and state module\n~~~~~~~~~~~~~~~~~~~~~~~~~~\nThis formula provides a custom execution module and state to manage packages installed with asdf. The functions are self-explanatory, please see the source code or the rendered docs at :ref:`em_asdf` and :ref:`sm_asdf`.\n\nConfiguration\n-------------\n\nThis formula\n~~~~~~~~~~~~\nThe general configuration structure is in line with all other formulae from the `tool` suite, for details see :ref:`toolsuite`. An example pillar is provided, see :ref:`pillar.example`. Note that you do not need to specify everything by pillar. Often, it's much easier and less resource-heavy to use the ``parameters/\u003cgrain\u003e/\u003cvalue\u003e.yaml`` files for non-sensitive settings. The underlying logic is explained in :ref:`map.jinja`.\n\nUser-specific\n^^^^^^^^^^^^^\nThe following shows an example of ``tool_asdf`` per-user configuration. If provided by pillar, namespace it to ``tool_global:users`` and/or ``tool_asdf:users``. For the ``parameters`` YAML file variant, it needs to be nested under a ``values`` parent key. The YAML files are expected to be found in\n\n1. ``salt://tool_asdf/parameters/\u003cgrain\u003e/\u003cvalue\u003e.yaml`` or\n2. ``salt://tool_global/parameters/\u003cgrain\u003e/\u003cvalue\u003e.yaml``.\n\n.. code-block:: yaml\n\n  user:\n\n      # Force the usage of XDG directories for this user.\n    xdg: true\n\n      # Put shell completions into this directory, relative to user home.\n    completions: '.config/zsh/completions'\n\n      # Sync this user's config from a dotfiles repo.\n      # The available paths and their priority can be found in the\n      # rendered `config/sync.sls` file (currently, @TODO docs).\n      # Overview in descending priority:\n      # salt://dotconfig/\u003cminion_id\u003e/\u003cuser\u003e/asdf\n      # salt://dotconfig/\u003cminion_id\u003e/asdf\n      # salt://dotconfig/\u003cos_family\u003e/\u003cuser\u003e/asdf\n      # salt://dotconfig/\u003cos_family\u003e/asdf\n      # salt://dotconfig/default/\u003cuser\u003e/asdf\n      # salt://dotconfig/default/asdf\n    dotconfig:              # can be bool or mapping\n      file_mode: '0600'     # default: keep destination or salt umask (new)\n      dir_mode: '0700'      # default: 0700\n      clean: false          # delete files in target. default: false\n\n      # Persist environment variables used by this formula for this\n      # user to this file (will be appended to a file relative to $HOME)\n    persistenv: '.config/zsh/zshenv'\n\n      # Add runcom hooks specific to this formula to this file\n      # for this user (will be appended to a file relative to $HOME)\n    rchook: '.config/zsh/zshrc'\n\n      # This user's configuration for this formula. Will be overridden by\n      # user-specific configuration in `tool_asdf:users`.\n      # Set this to `false` to disable configuration for this user.\n    asdf:\n        # plugin: version to install. Can be True (for latest), list or string.\n      direnv: 2.30.3\n      golang: latest\n        # If direnv is installed, make sure envrc files can use asdf.\n      integrate_direnv: true\n      nodejs: 17.8.0\n      php: 8.1.4\n      python: 3.10.3\n      ruby: 3.1.0\n      rust: latest\n        # User-specific defaults of global tool versions.\n      system:\n        python: 3.10.3\n        # Keep plugins updated to latest version on subsequent runs.\n      update_auto: true\n\nFormula-specific\n^^^^^^^^^^^^^^^^\n\n.. code-block:: yaml\n\n  tool_asdf:\n\n      # Specify an explicit version (works on most Linux distributions) or\n      # keep asdf updated to the latest version on subsequent runs\n      # by leaving version empty or setting it to 'latest'\n      # (again for Linux, brew does that anyways).\n    version: latest\n\n      # Default formula configuration for all users.\n    defaults:\n      update_auto: default value for all users\n\n\nGlobal files\n~~~~~~~~~~~~\nSome tools need global configuration files. A default one is provided with the formula, but can be overridden via the TOFS pattern. See :ref:`tofs_pattern` for details.\n\nDotfiles\n~~~~~~~~\n``tool_asdf.config.sync`` will recursively apply templates from\n\n* ``salt://dotconfig/\u003cminion_id\u003e/\u003cuser\u003e/asdf``\n* ``salt://dotconfig/\u003cminion_id\u003e/asdf``\n* ``salt://dotconfig/\u003cos_family\u003e/\u003cuser\u003e/asdf``\n* ``salt://dotconfig/\u003cos_family\u003e/asdf``\n* ``salt://dotconfig/default/\u003cuser\u003e/asdf``\n* ``salt://dotconfig/default/asdf``\n\nto the user's config dir for every user that has it enabled (see ``user.dotconfig``). The target folder will not be cleaned by default (ie files in the target that are absent from the user's dotconfig will stay).\n\nThe URL list above is in descending priority. This means user-specific configuration from wider scopes will be overridden by more system-specific general configuration.\n\n\nAvailable states\n----------------\n\nThe following states are found in this formula:\n\n.. contents::\n   :local:\n\n\n``tool_asdf``\n~~~~~~~~~~~~~\n*Meta-state*.\n\nPerforms all operations described in this formula according to the specified configuration.\n\n\n``tool_asdf.package``\n~~~~~~~~~~~~~~~~~~~~~\nInstalls the asdf package only.\n\n\n``tool_asdf.xdg``\n~~~~~~~~~~~~~~~~~\nEnsures asdf adheres to the XDG spec\nas best as possible for all managed users.\nHas a dependency on `tool_asdf.package`_.\n\n\n``tool_asdf.config``\n~~~~~~~~~~~~~~~~~~~~\nManages the asdf package configuration by\n\n* recursively syncing from a dotfiles repo\n\nHas a dependency on `tool_asdf.package`_.\n\n\n``tool_asdf.completions``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.system``\n~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.system.configure``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.direnv``\n~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.direnv.hook``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.direnv.integrate``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.direnv.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.golang``\n~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.golang.deps``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.golang.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.golang.xdg``\n~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.nodejs``\n~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.nodejs.deps``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.nodejs.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.nodejs.xdg``\n~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.php``\n~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.php.deps``\n~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.php.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.python``\n~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.python.deps``\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.python.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.python.xdg``\n~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.ruby``\n~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.ruby.deps``\n~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.ruby.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.ruby.xdg``\n~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.rust``\n~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.rust.package``\n~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.rust.xdg``\n~~~~~~~~~~~~~~~~~~~~~~\n\n\n\n``tool_asdf.clean``\n~~~~~~~~~~~~~~~~~~~\n*Meta-state*.\n\nUndoes mostly everything performed in the ``tool_asdf`` meta-state\nin reverse order.\n\n\n``tool_asdf.package.clean``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~\nRemoves the asdf package.\nHas a dependency on `tool_asdf.config.clean`_.\n\n\n``tool_asdf.xdg.clean``\n~~~~~~~~~~~~~~~~~~~~~~~\nRemoves asdf XDG compatibility crutches for all managed users.\n\n\n``tool_asdf.config.clean``\n~~~~~~~~~~~~~~~~~~~~~~~~~~\nRemoves the configuration of the asdf package.\n\n\n``tool_asdf.completions.clean``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nRemoves asdf completions for all managed users.\n\n\n\nDevelopment\n-----------\n\nContributing to this repo\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\nCommit messages\n^^^^^^^^^^^^^^^\n\nCommit message formatting is significant.\n\nPlease see `How to contribute \u003chttps://github.com/saltstack-formulas/.github/blob/master/CONTRIBUTING.rst\u003e`_ for more details.\n\npre-commit\n^^^^^^^^^^\n\n`pre-commit \u003chttps://pre-commit.com/\u003e`_ is configured for this formula, which you may optionally use to ease the steps involved in submitting your changes.\nFirst install  the ``pre-commit`` package manager using the appropriate `method \u003chttps://pre-commit.com/#installation\u003e`_, then run ``bin/install-hooks`` and\nnow ``pre-commit`` will run automatically on each ``git commit``.\n\n.. code-block:: console\n\n  $ bin/install-hooks\n  pre-commit installed at .git/hooks/pre-commit\n  pre-commit installed at .git/hooks/commit-msg\n\nState documentation\n~~~~~~~~~~~~~~~~~~~\nThere is a script that semi-autodocuments available states: ``bin/slsdoc``.\n\nIf a ``.sls`` file begins with a Jinja comment, it will dump that into the docs. It can be configured differently depending on the formula. See the script source code for details currently.\n\nThis means if you feel a state should be documented, make sure to write a comment explaining it.\n\nTodo\n----\n- finish migration to new format for subcomponents\n- allow arbitrary plugins (easily doable with new format)\n- generalize plugins to definitions to avoid repetition. maybe like that:\n\n  .. code-block:: yaml\n\n    python:\n      dependencies:\n        - list\n        - of\n        - pkgs\n      xdg_vars:\n        config:\n          - GIMME_BLOODY_XDG_YO: .default-stuff\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flkubb%2Fsalt-tool-asdf-formula","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flkubb%2Fsalt-tool-asdf-formula","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flkubb%2Fsalt-tool-asdf-formula/lists"}