{"id":16410691,"url":"https://github.com/thibaut-mouton/react-electron-autoupdate-with-gitlab","last_synced_at":"2026-04-30T08:39:33.625Z","repository":{"id":115669310,"uuid":"349198333","full_name":"Thibaut-Mouton/react-electron-autoupdate-with-gitlab","owner":"Thibaut-Mouton","description":"Sample of electron app built with react and with auto-update feature and Gitlab","archived":false,"fork":false,"pushed_at":"2021-03-18T20:33:04.000Z","size":171,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-06T02:45:35.818Z","etag":null,"topics":["autoupdater","electron","electron-app","electron-application","electron-builder","gitlab","gitlab-ci","gitlab-runner","react","reactjs","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Thibaut-Mouton.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-03-18T19:44:49.000Z","updated_at":"2024-06-25T09:08:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"5481b753-73f8-4ab7-ab80-c2631dc63a15","html_url":"https://github.com/Thibaut-Mouton/react-electron-autoupdate-with-gitlab","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thibaut-Mouton%2Freact-electron-autoupdate-with-gitlab","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thibaut-Mouton%2Freact-electron-autoupdate-with-gitlab/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thibaut-Mouton%2Freact-electron-autoupdate-with-gitlab/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thibaut-Mouton%2Freact-electron-autoupdate-with-gitlab/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Thibaut-Mouton","download_url":"https://codeload.github.com/Thibaut-Mouton/react-electron-autoupdate-with-gitlab/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240415269,"owners_count":19797603,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["autoupdater","electron","electron-app","electron-application","electron-builder","gitlab","gitlab-ci","gitlab-runner","react","reactjs","typescript"],"created_at":"2024-10-11T06:43:39.437Z","updated_at":"2026-04-30T08:39:28.571Z","avatar_url":"https://github.com/Thibaut-Mouton.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n![Electron logo](assets/electron.png \"Electron logo\")\n\u003c/div\u003e\n\n# Electron \u0026 React : Build autoUpdate feature on Gitlab private repository\n\nThis project shows how to deploy auto-update feature on electron project hosted on Gitlab. Electron's auto-updater module allow downloading new versions automatically. \n\n## 1. Generate Gitlab token\n\n\u003cdiv align=\"center\"\u003e\n\n![Gitlab token logo](assets/gitlab-token.JPG \"Creation of gitlab token\")\n\u003c/div\u003e\n\nCreate your own token with API scope.\n\n## 2. Change ```package.json``` and ```main.ts``` with your own settings \n##### package.json :\n```JSON\n\"repository\": {\n  \"type\": \"git\",\n  \"url\": \"https://gitlab.com/your-gitlab-username/your-repository-name/\"\n}\n```\n```JSON\n\"publish\": {\n\"provider\": \"generic\",\n\"url\": \"https://gitlab.com/api/v4/projects/Your-project-id/jobs/artifacts/your-branch-name/raw/dist?job=build\"\n}\n```\n\n##### electron/main.ts\n```Javascript\n// Auto update feature\nautoUpdater.requestHeaders = {\"PRIVATE-TOKEN\": \"your-gitlab-token\"};\n```\n\n## 3. Build app and launch it locally\n\nRun ```yarn run electron:build``` to build your app. Run ```mercure.exe``` with command line or by double-clicking it.\nYou can see there is no new version available\n\n## 4. Change files and push to repository\n\nIf you want to commit and publish a new version on your repository, don't forget to change the package.json version. Otherwise the auto-updater module won't be able to detect a new version\n\n##### package.json :\n```\n\"version\": \"1.5.0\"\n```\n\nThe commit will trigger gitlab pipeline :\n```\nUploading artifacts for successful job\nUploading artifacts...\ndist/: found 421 matching files and directories    \nUploading artifacts as \"archive\" to coordinator... ok \nCleaning up file based variables\nJob succeeded\n```\n\nOnce the pipeline is finished, a new version is available at https://gitlab.com/your-username/your-repo-name/-/jobs/job-ID/artifacts/file\nThe ```latest.yml``` file is very important because it contains the version id.\n\n## 5. Run your app\n\nYou should see this message : \n\n\u003cdiv align=\"center\"\u003e\n\n![Update available](assets/update-available.JPG \"Update available\")\n\u003c/div\u003e\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthibaut-mouton%2Freact-electron-autoupdate-with-gitlab","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthibaut-mouton%2Freact-electron-autoupdate-with-gitlab","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthibaut-mouton%2Freact-electron-autoupdate-with-gitlab/lists"}