be23f1390115058dc0fd6bb7664fb95255694f45
[webi-installers/.git] / pathman / releases.js
1 'use strict';
2
3 var github = require('../_common/gitea.js');
4 var owner = 'coolaj86';
5 var repo = 'go-pathman';
6 var baseurl = 'https://git.coolaj86.com';
7
8 module.exports = function (request) {
9   return github(request, owner, repo, baseurl).then(function (all) {
10     all.releases.forEach(function (rel) {
11       // TODO name uploads with arch, duh
12       if (!rel.arch) {
13         rel.arch = 'amd64';
14       }
15     });
16     return all;
17   });
18 };
19
20 if (module === require.main) {
21   module.exports(require('@root/request')).then(function (all) {
22     console.log(JSON.stringify(all, null, 2));
23   });
24 }