You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 11, 2018. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+32-26Lines changed: 32 additions & 26 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -49,56 +49,62 @@ apm install tool-bar-almighty
49
49
50
50
## Options
51
51
52
-
You have the ability to include [custom entries](https://github.com/varemenos/atom-toolbar-almighty#custom-entries).
53
-
You also have the ability to load the [suggested defaults](https://github.com/varemenos/atom-toolbar-almighty#toolbar-entries) along side your custom entries, or only the custom entries.
52
+
1.You have the ability to include [custom entries](https://github.com/varemenos/atom-toolbar-almighty#custom-entries).
53
+
2.You also have the ability to load the [suggested defaults](https://github.com/varemenos/atom-toolbar-almighty#toolbar-entries) along side your custom entries, or only the custom entries.
54
54
55
55
## Custom entries
56
56
57
-
I've added basic support for custom entries in v0.4. To utilize this feature you have to go to the settings of tool-bar-almighty and enter a path relative to your `.atom` directory that contains the entries you want to add. They will be added below the default entries.
57
+
You have the ability to include custom entries in the tool-bar-almighty by enabling the option in the package settings and entering a path relative to your `.atom` directory (that contains the entries you want to add).
58
58
59
-
The file must be a javascript module that exports an Array of entries.
59
+
The file must be in JSON format that contains an Array of entries.
60
60
61
61
### Format
62
62
63
-
The format is the same as [tool-bar's](https://github.com/suda/tool-bar#example) with 2 extra properties. The first one is `type` which indicates whether the entry is a `button` or a `spacer` while the second one is `dependency` which indicates whether a button's package is not installed by default in Atom and should only be displayed if it's package is installed.
64
-
The `lib/entries.coffee` is another example on how to format your entries.
63
+
The format is based on [tool-bar's](https://github.com/suda/tool-bar#example) but include 2 extra properties.
64
+
65
+
1.`type` indicates whether the entry is a `button` or a `spacer`
66
+
2.`dependency` indicates whether a button's package is not installed by default in Atom and should only be displayed if it's package is installed.
65
67
66
68
### Example
67
69
68
-
*The file's location `~/.atom/custom_entries.js`
69
-
* The tool-bar-almighty setting's value must match the filename mentioned above `custom_entries.js`
70
+
*Create a file inside `.atom`'s directory, in this case `~/.atom/custom_entries.json`
71
+
* The tool-bar-almighty setting's value must match the filename mentioned above `custom_entries.json` (relative to the `.atom` directory)
70
72
* The content of the file should look like the following:
71
73
72
-
```js
73
-
module.exports= [
74
+
```json
75
+
[
76
+
{
77
+
"type": "button",
78
+
"tooltip": "Open File",
79
+
"callback": "application:open-file",
80
+
"icon": "document-text",
81
+
"iconset": "ion"
82
+
},
74
83
{
75
-
type:'button',
76
-
tooltip:'Open File',
77
-
callback:'application:open-file',
78
-
icon:'document-text',
79
-
iconset:'ion'
84
+
"type": "spacer"
80
85
},
81
86
{
82
-
type:'button',
83
-
tooltip:'Open Folder',
84
-
callback:'application:open-folder',
85
-
icon:'folder',
86
-
iconset:'ion'
87
+
"type": "button",
88
+
"tooltip": "Open Folder",
89
+
"callback": "application:open-folder",
90
+
"icon": "folder",
91
+
"iconset": "ion"
87
92
},
88
93
{
89
-
type:'button',
90
-
tooltip:'Merge Conflicts',
91
-
dependency:'merge-conflicts',
92
-
callback:'merge-conflicts:detect',
93
-
icon:'code-fork',
94
-
iconset:'fa'
94
+
"type": "button",
95
+
"tooltip": "Merge Conflicts",
96
+
"dependency": "merge-conflicts",
97
+
"callback": "merge-conflicts:detect",
98
+
"icon": "code-fork",
99
+
"iconset": "fa"
95
100
}
96
101
]
97
102
```
98
103
99
104
## Known Issues / FAQ
100
105
101
106
* We've decided to remove the term2/term3 entries from the default entries, for more details and a possible fix read [this](https://github.com/varemenos/atom-toolbar-almighty/issues/9) issue's thread.
107
+
* We've decided to only support the JSON format for the custom entries to prevent future formating issues.
0 commit comments