{"id":15712394,"url":"https://github.com/xxiaoa/xdm","last_synced_at":"2025-07-05T17:04:48.966Z","repository":{"id":58079921,"uuid":"528064314","full_name":"XXiaoA/xdm","owner":"XXiaoA","description":"XXiaoA's dotfiles manager","archived":false,"fork":false,"pushed_at":"2023-01-08T10:03:54.000Z","size":314,"stargazers_count":9,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-08T11:07:54.394Z","etag":null,"topics":["configuration","dotfile","dotfiles","dotfiles-manager","rust","yaml"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/XXiaoA.png","metadata":{"files":{"readme":"README.md","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}},"created_at":"2022-08-23T15:59:36.000Z","updated_at":"2024-09-03T16:18:24.000Z","dependencies_parsed_at":"2023-02-08T05:31:02.773Z","dependency_job_id":null,"html_url":"https://github.com/XXiaoA/xdm","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XXiaoA%2Fxdm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XXiaoA%2Fxdm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XXiaoA%2Fxdm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XXiaoA%2Fxdm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/XXiaoA","download_url":"https://codeload.github.com/XXiaoA/xdm/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253146998,"owners_count":21861518,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["configuration","dotfile","dotfiles","dotfiles-manager","rust","yaml"],"created_at":"2024-10-03T21:15:58.826Z","updated_at":"2025-05-08T20:38:29.386Z","avatar_url":"https://github.com/XXiaoA.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# xdm\nXXiaoA's dotfiles manager\n![Screenshot](./Screenshot.jpg)\n\n**[🇨🇳中文](./README_zh.md)**\n\n\n## Install\n### Releases\nDownload the file from [releases](https://github.com/XXiaoA/xdm/releases)\n\n### Crates.io\nDownload from [crates.io](https://crates.io/crates/xdm): `cargo install xdm`. And remember to add `~/.cargo/bin/` into your $PATH\n\n### From source\nClone the source code with git. Then run `cargo install --path .`. And remember to add `~/.cargo/bin/` into your $PATH\n\n### AUR\nhttps://aur.archlinux.org/packages/xdm\n```sh\nparu -S xdm\n```\n\n\n## Usage\n\u003e Run `xdm -h` for more details\n\nFirst you should create a **yaml** file named `xdm.yaml` (not prerequisite, but **recommend**).\n\nThen you can run `xdm s` in a directory which has the yaml file. Xdm will find the `xdm.yaml` automatically in the current directory. Or you're able to use `xdm s file.yaml` to specify a yaml file.\n\nAlso, you can link a specific a directory or file.\n\n\n### Manual\nYou can set `manual` true in your link parameter (see [configuration](#configuration)).\n\nIf a link is manual, it won't be crated after run `xdm s`. But you can create it manually:\n```shell\nxdm link {path}\n```\n\nAlso, `link` command can work in all links, whether it'is manual or not.\n\nAnd you can crate all links with `xdm s -a`\n\n### Add\nYou can use `add` command to add a link item into your configuration automatically. For example:\n```shell\nxdm a a\n```\n\nThen the following will add into your configuration:\n```yaml\nlink:\n  # add by xdm\n  a:\n    path: b\n```\n\nBTW, the link is added is absolutize. And it don't use a simple way: `a: b` in order to let you add other parameter more easily.\n\n**Notice**: This feature will change your configuration. Your configuration probably be messy, but it still legal. Maybe fix it in the futrue.\n\n\n## Configuration\nFor example:\n```yaml\nlink:\n  ./path-to-original-file:\n    path: ./path-to-linked-file\n\n  ./nvim: ~/repos/nvim\n\n  ./tmux:\n    path: ~/.tmux.conf\n    if: test -e /usr/bin/tmux # for fish shell\n\ncreate:\n  - ~/repos\n```\nNotice: you must have `link` option.\n\n\n###  Link\nLink a file/directory.\n\nWhat's more, the two following form is same, it can reduce your work:\n```yaml\nlink:\n  ./a:\n    path: b\n\n  ./a: b\n```\n\n| Parameter | Explanation                                           | type   | default |\n| ---       | ---                                                   | ---    | :---:   |\n| path      | The file path to linked file                          | string | \\\\      |\n| exist     | Only create the link if the original file exists      | bool   | true    |\n| force     | Create the link whether the linked file exists or not | bool   | false   |\n| if        | Create the link if shell command is true (WIP)        | string | \\\\      |\n| create    | Create the parent directory of link if need           | bool   | true    |\n| manual    | Check [here](#manual)                                 | bool   | false   |\n| relink    | Auto relink if the linked path is a link              | bool   | true    |\n\n### Create\nCreate a directory\n\n\n## Others\ninspried by [dotbot](https://github.com/anishathalye/dotbot)\n\n### Notice\nWhether `path-to-linked-file` is a directory or file, it shouldn't end with `/`.\n\nBut `path-to-original-file` should end with `/` or not is base on yourself.\n\n### Full example\n[XXiaoA/dotfiles](https://github.com/XXiaoA/dotfiles)\n\n### TODO\n- [x] add support for AUR\n\n## License\n[GNU General Public License v3.0](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxxiaoa%2Fxdm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxxiaoa%2Fxdm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxxiaoa%2Fxdm/lists"}