1
0
mirror of https://github.com/S2-/gitlit synced 2025-08-03 21:00:04 +02:00

7 Commits

Author SHA1 Message Date
s2
b540eae1b9 1.5.1 2020-05-09 12:22:28 +02:00
s2
8f3705ba74 show gitlit version in window title 2020-05-09 12:22:21 +02:00
s2
e032eb2ab0 1.5.0 2020-05-09 12:10:34 +02:00
s2
519d719545 auto updater 2020-05-09 12:10:25 +02:00
s2
f8076499ba build windows portable binary 2020-05-09 12:09:23 +02:00
s2
edeadfd7fc 1.4.4 2020-05-06 20:23:03 +02:00
s2
9c26b8fb10 bump exec maxBuffer size to 10MB 2020-05-06 20:22:47 +02:00
4 changed files with 43 additions and 12 deletions

View File

@@ -3,7 +3,6 @@
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>gitlit</title>
<script>if (typeof module === 'object') {window.module = module; module = undefined;}</script> <script>if (typeof module === 'object') {window.module = module; module = undefined;}</script>

View File

@@ -13,9 +13,11 @@ let win;
let repoDir = path.resolve(path.normalize(args._.join(' '))); let repoDir = path.resolve(path.normalize(args._.join(' ')));
let repoRootDir = repoDir; let repoRootDir = repoDir;
require('update-electron-app')();
function getLfsFileList(dir, cb) { function getLfsFileList(dir, cb) {
exec('git ls-files | git check-attr --stdin lockable', { exec('git ls-files | git check-attr --stdin lockable', {
maxBuffer: 1024 * 1024, maxBuffer: (1024 * 1024) * 10, //10MB
cwd: dir cwd: dir
}, },
(error, stdout, stderr) => { (error, stdout, stderr) => {
@@ -47,7 +49,7 @@ function getLfsFileList(dir, cb) {
function getLfsLocks(dir, cb) { function getLfsLocks(dir, cb) {
exec('git lfs locks', { exec('git lfs locks', {
maxBuffer: 1024 * 1024, maxBuffer: (1024 * 1024) * 10, //10MB
cwd: dir cwd: dir
}, },
(error, stdout, stderr) => { (error, stdout, stderr) => {
@@ -126,7 +128,7 @@ function loadRepoPage() {
function createWindow() { function createWindow() {
// Create the browser window. // Create the browser window.
win = new BrowserWindow({width: 800, height: 700}); win = new BrowserWindow({title: 'gitlit v' + app.getVersion(), width: 800, height: 700});
win.setMenu(null); win.setMenu(null);
// and load the index.html of the app. // and load the index.html of the app.
@@ -147,7 +149,7 @@ function createWindow() {
function startup(cb) { function startup(cb) {
exec('git rev-parse --show-toplevel', { exec('git rev-parse --show-toplevel', {
maxBuffer: 1024 * 1024, maxBuffer: (1024 * 1024) * 10, //10MB
cwd: repoDir cwd: repoDir
}, },
(error, stdout, stderr) => { (error, stdout, stderr) => {
@@ -170,7 +172,7 @@ function startup(cb) {
ipcMain.on('unlock', (event, file) => { ipcMain.on('unlock', (event, file) => {
exec('git lfs unlock "' + file + '"', { exec('git lfs unlock "' + file + '"', {
maxBuffer: 1024 * 1024, maxBuffer: (1024 * 1024) * 10, //10MB
cwd: repoDir cwd: repoDir
}, },
(error, stdout, stderr) => { (error, stdout, stderr) => {
@@ -193,7 +195,7 @@ ipcMain.on('unlock', (event, file) => {
ipcMain.on('lock', (event, file) => { ipcMain.on('lock', (event, file) => {
exec('git lfs lock --json "' + file + '"', { exec('git lfs lock --json "' + file + '"', {
maxBuffer: 1024 * 1024, maxBuffer: (1024 * 1024) * 10, //10MB
cwd: repoDir cwd: repoDir
}, },
(error, stdout, stderr) => { (error, stdout, stderr) => {

31
package-lock.json generated
View File

@@ -1,6 +1,6 @@
{ {
"name": "gitlit", "name": "gitlit",
"version": "1.4.3", "version": "1.5.1",
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {
@@ -871,6 +871,11 @@
"resolved": "https://registry.npmjs.org/electron-is-accelerator/-/electron-is-accelerator-0.1.2.tgz", "resolved": "https://registry.npmjs.org/electron-is-accelerator/-/electron-is-accelerator-0.1.2.tgz",
"integrity": "sha1-UJ5RDCala1Xhf4Y6SwThEYRqsns=" "integrity": "sha1-UJ5RDCala1Xhf4Y6SwThEYRqsns="
}, },
"electron-is-dev": {
"version": "0.3.0",
"resolved": "https://registry.npmjs.org/electron-is-dev/-/electron-is-dev-0.3.0.tgz",
"integrity": "sha1-FOb9pcaOnk7L7/nM8DfL18BcWv4="
},
"electron-localshortcut": { "electron-localshortcut": {
"version": "3.2.1", "version": "3.2.1",
"resolved": "https://registry.npmjs.org/electron-localshortcut/-/electron-localshortcut-3.2.1.tgz", "resolved": "https://registry.npmjs.org/electron-localshortcut/-/electron-localshortcut-3.2.1.tgz",
@@ -1165,6 +1170,14 @@
"assert-plus": "^1.0.0" "assert-plus": "^1.0.0"
} }
}, },
"github-url-to-object": {
"version": "4.0.4",
"resolved": "https://registry.npmjs.org/github-url-to-object/-/github-url-to-object-4.0.4.tgz",
"integrity": "sha512-1Ri1pR8XTfzLpbtPz5MlW/amGNdNReuExPsbF9rxLsBfO1GH9RtDBamhJikd0knMWq3RTTQDbTtw0GGvvEAJEA==",
"requires": {
"is-url": "^1.1.0"
}
},
"global-dirs": { "global-dirs": {
"version": "0.1.1", "version": "0.1.1",
"resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-0.1.1.tgz", "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-0.1.1.tgz",
@@ -1376,6 +1389,11 @@
"integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=",
"dev": true "dev": true
}, },
"is-url": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/is-url/-/is-url-1.2.4.tgz",
"integrity": "sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww=="
},
"is-utf8": { "is-utf8": {
"version": "0.2.1", "version": "0.2.1",
"resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz", "resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz",
@@ -2558,6 +2576,17 @@
"integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==",
"dev": true "dev": true
}, },
"update-electron-app": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/update-electron-app/-/update-electron-app-1.5.0.tgz",
"integrity": "sha512-g7noW9JfQ8Hwq6zw9lmZei+R/ikOIBcaZ04TbmIcU5zNfv23HkN80QLLAyiR/47KvfS4sjnh2/wuDq5nh8+0mQ==",
"requires": {
"electron-is-dev": "^0.3.0",
"github-url-to-object": "^4.0.4",
"is-url": "^1.2.4",
"ms": "^2.1.1"
}
},
"update-notifier": { "update-notifier": {
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmjs.org/update-notifier/-/update-notifier-3.0.1.tgz", "resolved": "https://registry.npmjs.org/update-notifier/-/update-notifier-3.0.1.tgz",

View File

@@ -1,6 +1,6 @@
{ {
"name": "gitlit", "name": "gitlit",
"version": "1.4.3", "version": "1.5.1",
"description": "", "description": "",
"main": "app/main.js", "main": "app/main.js",
"build": { "build": {
@@ -38,7 +38,8 @@
"minimist": "^1.2.5", "minimist": "^1.2.5",
"nonblockjs": "^1.0.8", "nonblockjs": "^1.0.8",
"pnotify": "^4.0.1", "pnotify": "^4.0.1",
"popper.js": "^1.16.1" "popper.js": "^1.16.1",
"update-electron-app": "^1.5.0"
}, },
"devDependencies": { "devDependencies": {
"electron": "^3.1.13", "electron": "^3.1.13",
@@ -46,8 +47,8 @@
}, },
"scripts": { "scripts": {
"start": "electron .", "start": "electron .",
"pack": "electron-builder --linux --win --dir", "pack": "electron-builder --linux --win portable --dir",
"dist": "electron-builder --linux --win" "dist": "electron-builder --linux --win portable"
}, },
"repository": { "repository": {
"type": "git", "type": "git",