Get easy access to all your projects and manage them with project specific settings and options.
$ apm install project-manager
or open Atom and go to Preferences > Install and search for project-manager
ctrl-cmd-p
(mac) / alt-shift-P
(win & linux) or Project Manager: List Projects
in the Command Palette.
You can filter projects by title
, group
and template
.
group: atom
would list all projects with the group atom
. Default is title
Project Manager: Save Project
in the Command Palette and write the title you want to save the project as.
All projects are saved in a .cson
file which you can easily reach by searching for Project Manager: Edit Projects
in the Command Palette.
setting | Type | Description | Default |
---|---|---|---|
title |
string |
Projects title. Used in the projects list | '' |
paths |
array |
The folders that will open in the tree view. First path is the main one that counts as the project. | [] |
settings |
Object |
Enables you to set project specific settings. Everything that goes in the config.cson file can go here. It also supports scoped settings. |
{} |
icon |
string |
Icon that shows in the projects list. It's class-based so can either be a class already provided by Atom like icon-squirell or a class of your own. |
'icon-chevron-right' |
devMode |
boolean |
true if project should open in dev mode |
false |
group |
string |
Adds a group to the projects list that can be used to group and filter projects | null |
template |
string |
If you add a project in the projects.cson file without paths it will count as a template. This way you can easily share settings between projects |
null |
All these settings can be added to a project.cson
file in the root folder of the project. It follows the below example, but without the project key.
projectmanager:
title: 'Project Manager'
devMode: true
group: 'Atom'
template: 'coffeescript-template'
paths: [
'/path/to/project-manager'
]
settings:
'*':
'editor.tabLength': 4
'coffeescript-template':
icon: 'icon-coffeescript'
settings:
'.source.coffee':
'editor.tabLength': 2
'editor.preferredLineLength': 80
Name | Setting | Default | Description |
---|---|---|---|
Show Path | project-manager.showPath |
true |
Shows each projects paths in the projects list |
Environment Specific Projects | project-manager.environmentSpecificProjects |
false |
If you share your .atom folder between computers but don't use the same projects. Will create a projects.[hostname].cson for each environment |
Sort By | project-manager.sortBy |
'default' |
Will sort the projects list by selected option. Default sorting is the order in which the are |
Close Current | project-manager.closeCurrent |
false |
Closes the current window before opening a new project. |
The project manager provides a service that you can use in your own Atom packages. To use it, include project-manager
in the consumedServices
section of your package.json.
"consumedServices": {
"project-manager": {
"versions": {
"^2.2.1": "consumeProjectManager"
}
}
}
Then in your package's main module, call methods on the service
module.exports =
doSomethingWithTheCurrentProject: (project) ->
consumeProjectManager: (PM) ->
PM.projects.getCurrent (project) =>
if project
@doSomethingWithTheCurrentProject(project)
{Projects}
::getAll
{Function} callback
- Callback that receives an Array
of {Project}
's::getCurrent
{Function} callback
- Callback that receives the current {Project}
or false
if there is none active::onUpdate
{Function} callback
- Will be called each time a project have been updated{Project}
{props}
- Contains all properties of the project like title
, paths
and settings
::open
- Will open the project::isCurrent
- Returns true
if it's the current project::onUpdate
{Function} callback
- Will be called when the project have been updated::set
- Will set the property on the project
{String} key
{Mixed} value
::unset
- Will remove the property from the project
{String} key
Please let me know if you make something out of it :)
If you would like to contribute to the project manager, be it new features or bugs, please do the following:
All PR's should:
a if you enjoy using the project manager :)
Good catch. Let us know what about this package looks wrong to you, and we'll investigate right away.