/
example-repository.json
181 lines (164 loc) · 5.79 KB
/
example-repository.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
{
"schema_version": "2.0",
// Packages can be specified with a simple URL to a GitHub or BitBucket
// repository, but details can be overridden for every field. It is
// also possible not utilize GitHub or BitBucket at all, but just to
// host your packages on any server with an SSL certificate.
"packages": [
// This is what most packages should aim to model.
//
// The majority of the information about a package ("name",
// "description", "author") are all pulled from the GitHub (or
// BitBucket) repository info.
//
// If the word "sublime" exists in the repository name, the name
// can be overridden by the "name" key.
//
// A release is created from the the tag that is the highest semantic
// versioning version number in the list of tags.
{
"name": "Alignment",
"details": "https://github.com/wbond/sublime_alignment",
"releases": [
{
"details": "https://github.com/wbond/sublime_alignment/tags"
}
]
},
// Here is an equivalent package being pulled from BitBucket
{
"name": "Alignment",
"details": "https://bitbucket.org/wbond/sublime_alignment",
"releases": [
{
"details": "https://bitbucket.org/wbond/sublime_alignment#tags"
}
]
},
// Pull most details from GitHub, releases from master branch.
// This form is discouraged because users will upgrade to every single
// commit you make to master.
{
"details": "https://github.com/wbond/sublime_alignment"
},
// Pull most details from a BitBucket repository and releases from
// the branch "default" or "master", depending on how your repository
// is configured.
// Similar to the above example, this form is discouraged because users
// will upgrade to every single commit you make to master.
{
"details": "https://bitbucket.org/wbond/sublime_alignment"
},
// Use a custom name instead of just the URL slug
{
"name": "Alignment",
"details": "https://github.com/wbond/sublime_alignment"
},
// You can also override the homepage and author
{
"name": "Alignment",
"details": "https://github.com/wbond/sublime_alignment",
"homepage": "http://wbond.net/sublime_packages/alignment",
"author": "wbond"
},
// If you rename a package, you can provide the previous name(s)
// so that users with the old package name can be automatically
// upgraded to the new one.
{
"name": "Alignment",
"details": "https://github.com/wbond/sublime_alignment",
"previous_names": ["sublime_alignment"]
},
// In addition to the recommendation above of pulling releases
// from tags that are semantic version numbers, releases can also
// comefrom a custom branch.
{
"details": "https://github.com/wbond/sublime_alignment",
"releases": [
{
"details": "https://github.com/wbond/sublime_alignment/tree/custom_branch"
}
]
},
// An equivalent package being pulled from BitBucket.
{
"details": "https://bitbucket.org/wbond/sublime_alignment",
"releases": [
{
"details": "https://bitbucket.org/wbond/sublime_alignment/src/custom_branch"
}
]
},
// If your package is only compatible with specific builds of
// Sublime Text, this will cause the package to be hidden from
// users with incompatible versions.
{
"details": "https://github.com/wbond/sublime_alignment",
"releases": [
{
// Could also be >2999 for ST3. Leaving this out indicates
// the package works with both ST2 and ST3.
"sublime_text": "<3000",
"details": "https://github.com/wbond/sublime_alignment"
}
]
},
// The "platforms" key allows specifying what platform(s) the release
// is valid for. As shown, there can be multiple releases of a package
// at any given time. However, only the latest version for any given
// platform/arch will be shown to the user.
{
"details": "https://github.com/wbond/sublime_alignment",
"releases": [
{
// Defaults to all platforms. Can also specify the arch of
// the platform, e.g. "linux-x64"
"platforms": ["osx", "linux"],
"details": "https://github.com/wbond/sublime_alignment/tree/posix"
},
{
"platforms": "windows",
"details": "https://github.com/wbond/sublime_alignment/tree/win32"
}
]
},
// If you don't use a "details" key for a "releases" entry, you need to
// specify the "version", "url" and "date" manually.
{
"details": "https://github.com/wbond/sublime_alignment",
"releases": [
{
// The version number needs to be a semantic version number per
// http://semver.org 2.x.x
"version": "2.0.0",
// The URL needs to be a zip file containing the package. It is permissible
// for the zip file to contain a single root folder with any name. All
// file will be extracted out of this single root folder. This allows
// zip files from GitHub and BitBucket to be used a sources.
"url": "https://nodeload.github.com/wbond/sublime_alignment/zip/v2.0.0",
// The date MUST be in the form "YYYY-MM-DD HH:MM:SS" and SHOULD be UTC
"date": "2011-09-18 20:12:41"
}
]
}
],
// If you need/want to split your repository up into multiple smaller files
// for the sake of organization, the "includes" key allows you to enter
// relative file paths that will be combined together and dynamically inserted
// into the "packages" key.
"includes": [
// Relative file paths work for local filesystem access, or HTTP access.
//
// So, if this file was loaded from:
// "/home/wbond/example-repository.json",
// then the following file would be loaded from:
// "/home/wbond/repository/0-9.json"
//
// Similarly, if this file was loaded from
// "https://sublime.wbond.net/example-repository.json"
// then the following file would be loaded from:
// "https://sublime.wbond.net/repository/0-9.json"
"./repository/0-9.json",
"./repository/a.json"
]
}