Edit tree view

Hi!

I want to edit a few lines in the tree view package. How can I create a local new version of the tree view package?

You’ll clone the repository (to anywhere you like). You can use git from the command line or the github package to accomplish this. After it’s cloned, open your system’s command line application and navigate to the folder, then run apm install and apm link (this creates a symbolic link in .atom/packages/ that points to the cloned folder). Reload Atom and you will be using the copy of tree-view you downloaded instead of the built-in version.

Ok, ill try this:)

But if I move the folder into .atom/packages/, do I still need to run ‘apm link’? And also, what does apm install actually do?

Installing dependencies required by the package. Using npm or yarn should work as well, if you prefer them for whatever reason.

No, but then you run the risk of losing all of your changes if your packages are deleted. If you move computers and use a package to sync your packages (forgetting about the custom tree-view code, as it would be easy to do), you’ll lose it. If your computer suffers a catastrophic malfunction and you have to migrate all of your personal files out, there’s a chance you’ll forget about it. It’s safer to have the customized package live next to your other code projects, especially if you perform backups. Of course, you can also just use a GitHub account to maintain a fork of tree-view with your custom code, and then you don’t have to worry about anything.

If you want to fork on GitHub and keep your code safe that way, you can do that, then just run apm install https://github.com/johann1301h/tree-view and the package will be fully installed in .atom/packages/.

And also, what does apm install actually do?

Inside a package folder, if you don’t give it a target, it operates identically to npm install. If you give it a name or a GitHub repo, it will try to install the target as an Atom package.