Skip to content

Commit 2ecfb8e

Browse files
authored
Merge pull request #1 from YokiToki/v0.0.3
V0.0.3
2 parents 039e91f + a6c7a00 commit 2ecfb8e

30 files changed

+3086
-918
lines changed

.eslintrc.json

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
"env": {
3+
"browser": true,
4+
"es6": true
5+
},
6+
"extends": "prettier",
7+
"globals": {
8+
"Atomics": "readonly",
9+
"SharedArrayBuffer": "readonly"
10+
},
11+
"parserOptions": {
12+
"ecmaFeatures": {
13+
"jsx": true
14+
},
15+
"ecmaVersion": 2018,
16+
"sourceType": "module"
17+
},
18+
"plugins": [
19+
"react"
20+
],
21+
"rules": {
22+
"linebreak-style": [
23+
"error",
24+
"unix"
25+
],
26+
"quotes": [
27+
"warn",
28+
"single"
29+
],
30+
"semi": [
31+
"warn",
32+
"always"
33+
],
34+
"curly": [
35+
"warn",
36+
"all"
37+
]
38+
}
39+
}

.gitignore

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1+
.DS_Store
12
.idea/
3+
dist/
24
release/
3-
app/build/
4-
node_modules
5-
npm-debug.log
5+
node_modules/

.prettierrc

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"printWidth": 120,
3+
"tabWidth": 2,
4+
"useTabs": false,
5+
"semi": true,
6+
"singleQuote": true,
7+
"trailingComma": "all"
8+
}

.yarnclean

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# test directories
2+
__tests__
3+
node_modules/*/test
4+
node_modules/*/tests
5+
powered-test
6+
7+
# asset directories
8+
docs
9+
doc
10+
website
11+
images
12+
13+
# examples
14+
example
15+
examples
16+
17+
# code coverage directories
18+
coverage
19+
.nyc_output
20+
21+
# build scripts
22+
Makefile
23+
Gulpfile.js
24+
Gruntfile.js
25+
26+
# configs
27+
.tern-project
28+
.gitattributes
29+
.editorconfig
30+
.*ignore
31+
.eslintrc
32+
.jshintrc
33+
.flowconfig
34+
.documentup.json
35+
.yarn-metadata.json
36+
37+
# misc
38+
*.gz
39+
*.md

README.md

+10-4
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ For building on Windows you need install build tools.
2323
As Administrator run:
2424

2525
```
26-
> npm i -g --production windows-build-tools
26+
> yarn global add windows-build-tools
2727
```
2828

2929
And set environment variable:
@@ -39,19 +39,25 @@ Maybe you need download [Build Tools for Visual Studio](https://download.visuals
3939
Start the app in the `dev` environment:
4040

4141
```
42-
$ npm start
42+
$ yarn start
43+
```
44+
45+
If you got error, about incorrect version of native modules, try run following command:
46+
47+
```
48+
$ yarn build:deps
4349
```
4450

4551
## Building
4652

4753
To build apps (tar.gz, deb) for the linux:
4854

4955
```
50-
$ npm run build-linux
56+
$ yarn build-linux
5157
```
5258

5359
Windows portable:
5460

5561
```
56-
> npm run build-windows
62+
> yarn build-windows
5763
```

app/src/Storage.js

-38
This file was deleted.

app/src/entry.js

-8
This file was deleted.

main.js

-48
This file was deleted.

package.json

+49-34
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,57 @@
11
{
22
"name": "interkm",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"description": "Client application for read/write rw1990 keys",
5-
"main": "main.js",
5+
"author": {
6+
"name": "Stanislav Tamat",
7+
"email": "[email protected]"
8+
},
9+
"license": "MIT",
10+
"homepage": "https://yokitoki.github.io/interkm",
611
"scripts": {
7-
"serve": "electron .",
8-
"start": "cross-env NODE_ENV=development concurrently \"yarn run serve\" \"webpack --config webpack.config.dev.js --colors\"",
9-
"build": "cross-env NODE_ENV=production node --trace-warnings ./node_modules/webpack/bin/webpack --config webpack.config.prod.js --colors",
10-
"build-windows": "yarn run build && electron-builder --win --x64",
11-
"build-linux": "yarn run build && electron-builder --linux",
12-
"postinstall": "electron-builder install-app-deps"
12+
"start": "electron-webpack dev",
13+
"compile": "electron-webpack",
14+
"build:windows": "yarn compile && electron-builder --win --x64",
15+
"build:linux": "yarn compile && electron-builder --linux",
16+
"build:dir": "yarn dist --dir -c.compression=store -c.mac.identity=null",
17+
"build:clean": "rm -rf dist/ && rm -rf release/",
18+
"build:deps": "electron-builder install-app-deps",
19+
"build:publish": "electron-builder --publish onTag"
20+
},
21+
"electronWebpack": {
22+
"commonDistDirectory": "dist",
23+
"commonSourceDirectory": "src/common",
24+
"main": {
25+
"sourceDirectory": "src/main"
26+
},
27+
"renderer": {
28+
"sourceDirectory": "src/renderer",
29+
"webpackConfig": "src/renderer/config/webpack.config.js",
30+
"template": "src/renderer/public/index.html"
31+
}
32+
},
33+
"babel": {
34+
"presets": [
35+
"@babel/preset-react",
36+
"@babel/preset-env"
37+
]
1338
},
1439
"build": {
1540
"productName": "interkm",
1641
"appId": "io.github.yokitoki",
17-
"files": [
18-
"app/build/**/*",
19-
"app/src/assets/**/*",
20-
"app/index.html",
21-
"node_modules/**/*",
22-
"main.js",
23-
"package.json"
24-
],
42+
"publish": {
43+
"provider": "github"
44+
},
2545
"win": {
2646
"target": [
2747
"portable"
2848
]
2949
},
3050
"linux": {
3151
"target": [
52+
"tar.gz",
3253
"deb",
33-
"tar.gz"
54+
"appImage"
3455
],
3556
"category": "Development"
3657
},
@@ -39,34 +60,28 @@
3960
"output": "release"
4061
}
4162
},
42-
"author": {
43-
"name": "Stanislav Tamat",
44-
"email": "[email protected]"
45-
},
46-
"license": "MIT",
47-
"homepage": "https://yokitoki.github.io/interkm",
4863
"dependencies": {
4964
"bcrypt": "^4.0.0",
5065
"react": "^16.12.0",
5166
"react-dom": "^16.12.0",
52-
"serialport": "^8.0.7"
67+
"serialport": "^8.0.7",
68+
"source-map-support": "^0.5.12"
5369
},
5470
"devDependencies": {
5571
"@babel/core": "^7.8.4",
5672
"@babel/preset-env": "^7.8.4",
5773
"@babel/preset-react": "^7.8.3",
5874
"babel-loader": "^8.0.6",
59-
"concurrently": "^5.1.0",
60-
"cross-env": "^7.0.0",
61-
"css-loader": "^3.4.2",
62-
"electron": "^7.1.13",
75+
"electron": "7.1.13",
6376
"electron-builder": "^22.3.2",
64-
"electron-reload": "^1.5.0",
65-
"file-loader": "^5.1.0",
66-
"mini-css-extract-plugin": "^0.9.0",
67-
"webpack": "^4.41.6",
68-
"webpack-cli": "^3.3.11",
69-
"webpack-dev-server": "^3.10.3"
77+
"electron-webpack": "^2.7.4",
78+
"eslint": "^5.16.0",
79+
"eslint-config-prettier": "^4.2.0",
80+
"eslint-plugin-prettier": "^3.1.2",
81+
"eslint-plugin-react": "^7.12.4",
82+
"prettier": "^1.17.0",
83+
"prettier-eslint": "^8.8.2",
84+
"webpack": "^4.41.6"
7085
},
7186
"devEngines": {
7287
"node": ">=10.16.0",
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)