Disable packages based on what project/folder is opened?

I’d like certain packages to be disabled when I open certain folders/projects.

Is this automation possible?


I think that you have “profiles” in mind where you match a set of packages/configurations to one of a number of development profiles.

Search “profiles” for some earlier ideas.

I now use external automation scripts to orchestrate Atom profiles. It is much easier, I find. External automation approach depends on your OS (Windows/Linux/Mac).

Also look at package-list package which allows easy enable/disable packages. And project-viewer.

1 Like

Those 2 packages you mentioned are a great addition to my workflow, however, they are not what I’m looking for.

For example, there’s an auto-completion package called TabNine but I only like it when I’m writing nodejs/express code (in other projects I quite hate it). I have a package that provides p5js snippets but it usually pollutes my other javascript suggestions so I keep this package disabled unless working on a p5js project.

I’m looking for a package that will auto-enable/disable packages depending on what project I open. I did find a package that claimed to do this, however, it wasn’t working and I found out that that repo hasn’t been updated in 4 years.

I’ll keep looking.

Did you scan through all earlier published ideas on project profiles as suggested above (the blue hyperlink)?


So I just had another look and unfortunately I don’t see how those search results relate to what I need.

I don’t think I have the programming chops to do this but I’ll see if I can implement this myself. Basically, I want to have some sort of settings file in the root folder of a project. When atom loads, it should read that file, then enable or disable the packages listed in the settings via atom.packages.enablePackage()/disablePackage().

I was considering the broader goal of toggling variants of configuration files such as snippets in addition to setting a group of packages for each “profile”.
I did start this some time back and created two extra folders …
$HOME/.atom-profiles and $HOME/.atom-scripts … for profile switching and caching config files.
But if you only intend enabling/disabling a set of packages (no changes to any configuration files) then I would just create a bash or python script for each profile set and then call each script through custom process-palette command. That is what I use for commands such as Run Python, Run Java, and others.

1 Like

That seems like it would be easier to implement, I’ll give it a shot. Thanks!

(Still hoping to find a package that does that for me though :slight_smile: )

I’m not going to venture to write such a package.
But one workflow which seems to be adequate is to
leverage project-viewer package. Also look at project-viewer-plus by same author (read the docs for rationale).
This allows nested groups/projects.
Now at first level of tree in project-viewer panel
I rethink “group” as “profile”.
Then inside each profile (aka group) I point to various project folders which when clicked open in left hand project panel.
Now the top item inside each profile(group) can be a script (bash or py) which sets up a combination of packages/config files. Or you might just define just one group which contains a series of profile changing scripts.

1 Like