如何保存Atom编辑器配置和已安装软件包的列表 [英] How to save Atom editor config and list of packages installed
问题描述
我最近开始使用Atom编辑器.到目前为止,它还不错.我打算将其安装在其他几台计算机上.
I have recently started using Atom editor. Its pretty great so far. I am planning to install it on several other machines.
如何将当前计算机上安装的配置和软件包列表复制到其他计算机上.有没有可用于在其他计算机上导出和导入它们的配置.
How can I replicate the config and list of packages installed on my current machine to other machines. Is there a config that I can use to export and import them on other machines.
推荐答案
使用 Git 对版本进行控制文件(~/.atom/config.cson
)以及您可能拥有的任何其他配置文件(点文件).
Use Git to version control your config file (~/.atom/config.cson
), and any other config files (dotfiles) you may have.
然后,您可以在 GitHub 之类的地方免费托管Git存储库,只需运行git clone https://github.com/{username}/{repo}
.
You can then host your Git repository for free on somewhere like GitHub, and retrieve it on other computers simply by running git clone https://github.com/{username}/{repo}
.
然后您可以使用git push
(用于上传更改)和git pull
(用于下载更改)保持最新状态.
You can then keep it up to date using git push
(to upload changes) and git pull
(to download changes).
要跟踪安装的软件包,还需要运行:
To track installed packages as well, you will need to run:
apm list --installed --bare > ~/.atom/package.list
并将该文件也添加到Git中.要还原,请使用:
And add that file to Git also. To restore, use:
apm install --packages-file ~/.atom/package.list
这篇关于如何保存Atom编辑器配置和已安装软件包的列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!