This repository has been archived by the owner on Apr 22, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
7,798 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,8 @@ | ||
# EditorConfig helps developers define and maintain consistent | ||
# coding styles between different editors and IDEs | ||
# editorconfig.org | ||
|
||
root = true | ||
|
||
|
||
[*] | ||
|
||
# change these settings to your own preference | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
# we recommend you to keep these unchanged | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[*.json] | ||
indent_style = space | ||
indent_size = 2 | ||
insert_final_newline = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# don't ever lint node_modules | ||
node_modules/ | ||
# don't lint build output (make sure it's set to your correct build folder name) | ||
lib/ | ||
tmp/ | ||
test/*.js | ||
# don't lint templates | ||
templates/ | ||
# temporary ignore examples | ||
# examples/ | ||
# temporary ignore generated types, remove this if the heap out of memory bug is fixed | ||
@types/ | ||
*.js | ||
*/*.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// see https://www.robertcooper.me/using-eslint-and-prettier-in-a-typescript-project | ||
module.exports = { | ||
root: true, | ||
parser: '@typescript-eslint/parser', // Specifies the ESLint parser | ||
plugins: [ | ||
'@typescript-eslint', | ||
], | ||
extends: [ | ||
'eslint:recommended', | ||
'plugin:@typescript-eslint/eslint-recommended', | ||
'plugin:@typescript-eslint/recommended', // Uses the recommended rules from the @typescript-eslint/eslint-plugin | ||
], | ||
rules: { | ||
'no-debugger': 'off', | ||
'@typescript-eslint/no-explicit-any': 'off', | ||
'@typescript-eslint/no-misused-new': 'off', | ||
'@typescript-eslint/triple-slash-reference': 'off', | ||
// For Gjs | ||
'camelcase': 'off', | ||
'@typescript-eslint/camelcase': 'off' | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -78,3 +78,5 @@ tags | |
gschemas.compiled | ||
[email protected]*.zip | ||
_build | ||
node_modules | ||
@types |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = { | ||
environments: ['gjs'], | ||
modules: ['Gtk-3.0'], | ||
prettify: true, | ||
outdir: './@types', | ||
ignore: [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,73 +1,15 @@ | ||
# Extensions Sync | ||
# 🚀 Welcome to your new awesome project! | ||
|
||
Syncs gnome shell extensions and their configurations across all gnome installations with the help of gist | ||
This project has been created using **webpack scaffold**, you can now run | ||
|
||
![SS](https://i.imgur.com/2vJ89Zo.jpg) | ||
|
||
## Installation | ||
|
||
### From [Git](https://github.com/oae/gnome-shell-extensions-sync) | ||
|
||
```bash | ||
curl https://raw.githubusercontent.com/oae/gnome-shell-extensions-sync/master/installer.sh | bash | ||
``` | ||
npm run build | ||
``` | ||
|
||
### From [Ego](extensions.gnome.org) | ||
|
||
* You can install it from link below | ||
https://extensions.gnome.org/extension/1486/extensions-sync/ | ||
|
||
## Usage | ||
|
||
1. Create a new gist from [here](https://gist.github.com/) I suggest you make it secret. | ||
2. Create a new token from [here](https://github.com/settings/tokens/new). Only gist permission is needed since we edit the gists. | ||
3. Open extension settings and fill gist id from first step and gist token from second step. | ||
4. Enjoy! | ||
|
||
## Debugging | ||
|
||
* If you encounter a problem you can enable the debug logs with; | ||
|
||
```sh | ||
busctl --user call org.gnome.Shell /org/gnome/Shell org.gnome.Shell Eval s 'window.extensionsSync.debug = true;' | ||
``` | ||
|
||
* Then trace them with; | ||
|
||
```sh | ||
journalctl /usr/bin/gnome-shell -f -o cat | grep "\[extensions-sync\]" | ||
``` | ||
|
||
## Notes | ||
or | ||
|
||
* Downloading from gist will do 3 things. | ||
* It will remove all extensions that are not exist in the gist. | ||
* It will install extensions that are listed in gist and update their settings. | ||
* It will update all the settings of installed the extensions. | ||
|
||
* Uploading to gist will dump all the settings of the installed extensions(enabled/disabled) and put them in the gist with the below structure | ||
``` | ||
yarn build | ||
``` | ||
|
||
```json | ||
{ | ||
"description": "Extensions sync", | ||
"files": { | ||
"syncSettings": { | ||
"content": { | ||
"lastUpdatedAt": "time", | ||
} | ||
}, | ||
"extensions": { | ||
"content": { | ||
"extension1": { | ||
"schema1": "schema1 settings", | ||
"schema2": "schema2 settings", | ||
}, | ||
"extension2": { | ||
"schema1": "schema1 settings", | ||
"schema2": "schema2 settings", | ||
}, | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
to bundle your application |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,162 @@ | ||
/******/ (function(modules) { // webpackBootstrap | ||
/******/ // The module cache | ||
/******/ var installedModules = {}; | ||
/******/ | ||
/******/ // The require function | ||
/******/ function __webpack_require__(moduleId) { | ||
/******/ | ||
/******/ // Check if module is in cache | ||
/******/ if(installedModules[moduleId]) { | ||
/******/ return installedModules[moduleId].exports; | ||
/******/ } | ||
/******/ // Create a new module (and put it into the cache) | ||
/******/ var module = installedModules[moduleId] = { | ||
/******/ i: moduleId, | ||
/******/ l: false, | ||
/******/ exports: {} | ||
/******/ }; | ||
/******/ | ||
/******/ // Execute the module function | ||
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); | ||
/******/ | ||
/******/ // Flag the module as loaded | ||
/******/ module.l = true; | ||
/******/ | ||
/******/ // Return the exports of the module | ||
/******/ return module.exports; | ||
/******/ } | ||
/******/ | ||
/******/ | ||
/******/ // expose the modules object (__webpack_modules__) | ||
/******/ __webpack_require__.m = modules; | ||
/******/ | ||
/******/ // expose the module cache | ||
/******/ __webpack_require__.c = installedModules; | ||
/******/ | ||
/******/ // define getter function for harmony exports | ||
/******/ __webpack_require__.d = function(exports, name, getter) { | ||
/******/ if(!__webpack_require__.o(exports, name)) { | ||
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); | ||
/******/ } | ||
/******/ }; | ||
/******/ | ||
/******/ // define __esModule on exports | ||
/******/ __webpack_require__.r = function(exports) { | ||
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { | ||
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); | ||
/******/ } | ||
/******/ Object.defineProperty(exports, '__esModule', { value: true }); | ||
/******/ }; | ||
/******/ | ||
/******/ // create a fake namespace object | ||
/******/ // mode & 1: value is a module id, require it | ||
/******/ // mode & 2: merge all properties of value into the ns | ||
/******/ // mode & 4: return value when already ns object | ||
/******/ // mode & 8|1: behave like require | ||
/******/ __webpack_require__.t = function(value, mode) { | ||
/******/ if(mode & 1) value = __webpack_require__(value); | ||
/******/ if(mode & 8) return value; | ||
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; | ||
/******/ var ns = Object.create(null); | ||
/******/ __webpack_require__.r(ns); | ||
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); | ||
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); | ||
/******/ return ns; | ||
/******/ }; | ||
/******/ | ||
/******/ // getDefaultExport function for compatibility with non-harmony modules | ||
/******/ __webpack_require__.n = function(module) { | ||
/******/ var getter = module && module.__esModule ? | ||
/******/ function getDefault() { return module['default']; } : | ||
/******/ function getModuleExports() { return module; }; | ||
/******/ __webpack_require__.d(getter, 'a', getter); | ||
/******/ return getter; | ||
/******/ }; | ||
/******/ | ||
/******/ // Object.prototype.hasOwnProperty.call | ||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; | ||
/******/ | ||
/******/ // __webpack_public_path__ | ||
/******/ __webpack_require__.p = ""; | ||
/******/ | ||
/******/ | ||
/******/ // Load entry module and return exports | ||
/******/ return __webpack_require__(__webpack_require__.s = 0); | ||
/******/ }) | ||
/************************************************************************/ | ||
/******/ ([ | ||
/* 0 */ | ||
/***/ (function(module, exports, __webpack_require__) { | ||
|
||
module.exports = __webpack_require__(1); | ||
|
||
|
||
/***/ }), | ||
/* 1 */ | ||
/***/ (function(module, exports, __webpack_require__) { | ||
|
||
"use strict"; | ||
|
||
/* extension.js | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 2 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program. If not, see <http:https://www.gnu.org/licenses/>. | ||
* | ||
* SPDX-License-Identifier: GPL-2.0-or-later | ||
*/ | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
/* exported init */ | ||
const debug_1 = __webpack_require__(2); | ||
__webpack_require__(3); | ||
__webpack_require__(4); | ||
class Extension { | ||
enable() { | ||
debug_1.debug('-------------------enabled-------------------'); | ||
} | ||
disable() { | ||
debug_1.debug('-------------------disabled-------------------'); | ||
} | ||
} | ||
function init() { | ||
return new Extension(); | ||
} | ||
|
||
|
||
/***/ }), | ||
/* 2 */ | ||
/***/ (function(module, exports, __webpack_require__) { | ||
|
||
"use strict"; | ||
|
||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.debug = (str) => { | ||
log(str); | ||
}; | ||
|
||
|
||
/***/ }), | ||
/* 3 */ | ||
/***/ (function(module, exports, __webpack_require__) { | ||
|
||
// extracted by mini-css-extract-plugin | ||
|
||
/***/ }), | ||
/* 4 */ | ||
/***/ (function(module, __webpack_exports__, __webpack_require__) { | ||
|
||
"use strict"; | ||
__webpack_require__.r(__webpack_exports__); | ||
/* harmony default export */ __webpack_exports__["default"] = (__webpack_require__.p + "metadata.json"); | ||
|
||
/***/ }) | ||
/******/ ]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"name": "extensions-sync-x", | ||
"description": "extensions-sync-x", | ||
"uuid": "[email protected]", | ||
"shell-version": [ | ||
"3.36" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#asd{color:white} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{ | ||
"name": "extensions-sync-x", | ||
"version": "1.0.0", | ||
"author": "Alperen Elhan <[email protected]>", | ||
"license": "MIT", | ||
"scripts": { | ||
"build": "yarn run build:types && yarn run build:ts", | ||
"build:ts": "yarn run clear:ts && webpack", | ||
"build:types": "yarn run clear:types && ts-for-gir generate", | ||
"clear:types": "rm -rf ./@types", | ||
"clear:ts": "rm -rf ./dist", | ||
"clear": "yarn run clear:ts && yarn run build:types", | ||
"watch": "yarn run build -- --watch", | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"devDependencies": { | ||
"@typescript-eslint/eslint-plugin": "^2.23.0", | ||
"@typescript-eslint/parser": "^2.23.0", | ||
"css-loader": "^3.4.2", | ||
"eslint": "^6.8.0", | ||
"eslint-config-prettier": "^6.10.0", | ||
"eslint-plugin-prettier": "^3.1.2", | ||
"file-loader": "^5.1.0", | ||
"mini-css-extract-plugin": "^0.9.0", | ||
"node-sass": "^4.13.1", | ||
"prettier": "^1.19.1", | ||
"sass-loader": "^8.0.2", | ||
"style-loader": "^1.1.3", | ||
"ts-loader": "^6.2.1", | ||
"typescript": "^3.7.4", | ||
"webpack": "^4.41.5", | ||
"webpack-cli": "^3.3.10" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
"use strict"; | ||
exports.__esModule = true; | ||
exports.debug = function (str) { | ||
log(str); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export const debug = (str: string): void => { | ||
log(str); | ||
}; |
Oops, something went wrong.