Skip to content

Commit

Permalink
Merge branch 'upstream_development' into development
Browse files Browse the repository at this point in the history
Also, undid a weird change to the visibility of the instance picker
I made a long time ago, but don't know why I did it, so now,
it will be more like upstream again.

# Conflicts:
#	_scripts/webpack.workers.config.js
#	package.json
#	yarn.lock
  • Loading branch information
MarmadileManteater committed Nov 22, 2022
2 parents d6f871d + c8d37cd commit 263d158
Show file tree
Hide file tree
Showing 85 changed files with 2,668 additions and 1,793 deletions.
4 changes: 3 additions & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,12 @@ body:
options:
- label: I have encountered this bug in the [latest release of FreeTube](https://github.com/FreeTubeApp/FreeTube/releases).
required: true
- label: I have searched the [issue tracker](https://github.com/FreeTubeApp/FreeTube/issues) for open and closed issues that are similar to the bug report I want to file, without success.
- label: I have searched the issue tracker for [open](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aopen+is%3Aissue) and [closed](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aissue+is%3Aclosed) issues that are similar to the bug report I want to file, without success.
required: true
- label: I have searched the [documentation](https://docs.freetubeapp.io/) for information that matches the description of the bug I want to file, without success.
required: true
- label: This issue contains only one bug.
required: true
- type: textarea
attributes:
label: Describe the bug
Expand Down
4 changes: 3 additions & 1 deletion .github/ISSUE_TEMPLATE/feature_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@ body:
label: Guidelines
description: Please ensure you've completed all of the following.
options:
- label: I have searched the [issue tracker](https://github.com/FreeTubeApp/FreeTube/issues) for open and closed issues that are similar to the feature request I want to file, without success.
- label: I have searched the issue tracker for [open](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aopen+is%3Aissue) and [closed](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aissue+is%3Aclosed) issues that are similar to the feature request I want to file, without success.
required: true
- label: I have searched the [documentation](https://docs.freetubeapp.io/) for information that matches the description of the feature request I want to file, without success.
required: true
- label: This issue contains only one feature request.
required: true
- type: textarea
attributes:
label: Problem Description
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/autoLabelDuplicate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ jobs:
steps:
- uses: Amwam/[email protected]
with:
keywords: '["duplicate of"]'
keywords: '["duplicate of #", "duplicate of https://github.com/FreeTubeApp/FreeTube/issues/", "duplicate of https://github.com/FreeTubeApp/FreeTube/pulls/"]'
labels: '["U: duplicate"]'
github-token: "${{ secrets.GITHUB_TOKEN }}"
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build:
strategy:
matrix:
node-version: [16.x]
node-version: [18.x]
runtime:
- linux-x64
- linux-armv7l
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/flatpak.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,22 +77,22 @@ jobs:
date +"%Y-%m-%d" >> $GITHUB_ENV
echo 'EOF' >> $GITHUB_ENV
- name: Update x64 File Location in yml File
uses: mikefarah/yq@v4.29.2
uses: mikefarah/yq@4.0.0-beta1
with:
# The Command which should be run
cmd: yq w -i io.freetubeapp.FreeTube.yml modules[0].sources[0].url 'https://github.com/FreeTubeApp/FreeTube/releases/download/v${{ steps.sub.outputs.result }}-beta/freetube-${{ steps.sub.outputs.result }}-linux-portable-x64.zip'
- name: Update x64 Hash in yml File
uses: mikefarah/yq@v4.29.2
uses: mikefarah/yq@4.0.0-beta1
with:
# The Command which should be run
cmd: yq w -i io.freetubeapp.FreeTube.yml modules[0].sources[0].sha256 ${{ env.HASH_X64 }}
- name: Update ARM File Location in yml File
uses: mikefarah/yq@v4.29.2
uses: mikefarah/yq@4.0.0-beta1
with:
# The Command which should be run
cmd: yq w -i io.freetubeapp.FreeTube.yml modules[0].sources[1].url 'https://github.com/FreeTubeApp/FreeTube/releases/download/v${{ steps.sub.outputs.result }}-beta/freetube-${{ steps.sub.outputs.result }}-linux-portable-arm64.zip'
- name: Update ARM Hash in yml File
uses: mikefarah/yq@v4.29.2
uses: mikefarah/yq@4.0.0-beta1
with:
# The Command which should be run
cmd: yq w -i io.freetubeapp.FreeTube.yml modules[0].sources[1].sha256 ${{ env.HASH_ARM64 }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16.x
- name: Use Node.js 18.x
uses: actions/setup-node@v3
with:
node-version: 16.x
node-version: 18.x
cache: "yarn"
- run: yarn run ci
- run: yarn run lint
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build:
strategy:
matrix:
node-version: [16.x]
node-version: [18.x]
runtime:
- linux-x64
- linux-armv7l
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/remove-outdated-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
PR: changes requested
PR: merge conflicts / rebase needed
PR/Issue: dependent
PR: stale
remove-closed-pr-labels:
name: Remove closed pull request labels
Expand All @@ -33,4 +34,5 @@ jobs:
PR: WIP
PR: changes requested
PR: merge conflicts / rebase needed
PR/Issue: dependent
PR/Issue: dependent
PR: stale
2 changes: 1 addition & 1 deletion _scripts/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ if (platform === 'darwin') {

const config = {
appId: `io.freetubeapp.${name}`,
copyright: 'Copyleft © 2020-2021 [email protected]',
copyright: 'Copyleft © 2020-2022 [email protected]',
// asar: false,
// compression: 'store',
productName,
Expand Down
49 changes: 17 additions & 32 deletions _scripts/dev-runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ const { spawn } = require('child_process')
const mainConfig = require('./webpack.main.config')
const rendererConfig = require('./webpack.renderer.config')
const webConfig = require('./webpack.web.config')
const workersConfig = require('./webpack.workers.config')

let electronProcess = null
let manualRestart = null
Expand Down Expand Up @@ -72,41 +71,27 @@ async function restartElectron() {
}

function startMain() {
const webpackSetup = webpack([mainConfig, workersConfig])

webpackSetup.compilers.forEach(compiler => {
const { name } = compiler

switch (name) {
case 'workers':
compiler.hooks.afterEmit.tap('afterEmit', async () => {
console.log(`\nCompiled ${name} script!`)
console.log(`\nWatching file changes for ${name} script...`)
})
break
case 'main':
default:
compiler.hooks.afterEmit.tap('afterEmit', async () => {
console.log(`\nCompiled ${name} script!`)

manualRestart = true
await restartElectron()
setTimeout(() => {
manualRestart = false
}, 2500)

console.log(`\nWatching file changes for ${name} script...`)
})
break
}
const compiler = webpack(mainConfig)
const { name } = compiler

compiler.hooks.afterEmit.tap('afterEmit', async () => {
console.log(`\nCompiled ${name} script!`)

manualRestart = true
await restartElectron()
setTimeout(() => {
manualRestart = false
}, 2500)

console.log(`\nWatching file changes for ${name} script...`)
})

webpackSetup.watch({
compiler.watch({
aggregateTimeout: 500,
},
err => {
if (err) console.error(err)
})
err => {
if (err) console.error(err)
})
}

function startRenderer(callback) {
Expand Down
10 changes: 1 addition & 9 deletions _scripts/webpack.main.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ const config = {
},
node: {
__dirname: isDevMode,
__filename: isDevMode,
global: isDevMode,
__filename: isDevMode
},
plugins: [
new webpack.DefinePlugin({
Expand All @@ -48,13 +47,6 @@ const config = {
path: path.join(__dirname, '../dist'),
publicPath: ''
},
resolve: {
extensions: ['.js', '.json'],
alias: {
'@': path.join(__dirname, '../src/'),
src: path.join(__dirname, '../src/'),
},
},
target: 'electron-main',
}

Expand Down
18 changes: 3 additions & 15 deletions _scripts/webpack.renderer.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,7 @@ const config = {
},
node: {
__dirname: isDevMode,
__filename: isDevMode,
global: isDevMode,
__filename: isDevMode
},
plugins: [
new webpack.DefinePlugin({
Expand All @@ -131,14 +130,9 @@ const config = {
],
resolve: {
alias: {
vue$: 'vue/dist/vue.common.js',
'@': path.join(__dirname, '../src/'),
src: path.join(__dirname, '../src/'),
icons: path.join(__dirname, '../_icons/'),
images: path.join(__dirname, '../src/renderer/assets/img/'),
static: path.join(__dirname, '../static/'),
vue$: 'vue/dist/vue.common.js'
},
extensions: ['.js', '.vue', '.json'],
extensions: ['.js', '.vue']
},
target: 'electron-renderer',
}
Expand All @@ -157,12 +151,6 @@ if (!isDevMode) {
processLocalesPlugin,
new webpack.DefinePlugin({
'process.env.LOCALE_NAMES': JSON.stringify(processLocalesPlugin.localeNames)
}),
// webpack doesn't get rid of js-yaml even though it isn't used in the production builds
// so we need to manually tell it to ignore any imports for `js-yaml`
new webpack.IgnorePlugin({
resourceRegExp: /^js-yaml$/,
contextRegExp: /i18n$/
})
)
}
Expand Down
18 changes: 4 additions & 14 deletions _scripts/webpack.web.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,12 +136,7 @@ const config = {
],
resolve: {
alias: {
'@': path.join(__dirname, '../src/renderer'),
vue$: 'vue/dist/vue.esm.js',
src: path.join(__dirname, '../src/'),
icons: path.join(__dirname, '../_icons/'),
images: path.join(__dirname, '../src/renderer/assets/img/'),
static: path.join(__dirname, '../static/'),
vue$: 'vue/dist/vue.esm.js'
},
fallback: {
buffer: require.resolve('buffer/'),
Expand All @@ -155,9 +150,10 @@ const config = {
stream: require.resolve('stream-browserify'),
timers: require.resolve('timers-browserify'),
tls: require.resolve('browserify/lib/_empty.js'),
vm: require.resolve('vm-browserify')
vm: require.resolve('vm-browserify'),
zlib: require.resolve('browserify-zlib')
},
extensions: ['.js', '.vue', '.json', '.css'],
extensions: ['.js', '.vue']
},
target: 'web',
}
Expand Down Expand Up @@ -189,12 +185,6 @@ config.plugins.push(
},
},
]
}),
// webpack doesn't get rid of js-yaml even though it isn't used in the production builds
// so we need to manually tell it to ignore any imports for `js-yaml`
new webpack.IgnorePlugin({
resourceRegExp: /^js-yaml$/,
contextRegExp: /i18n$/
})
)

Expand Down
38 changes: 18 additions & 20 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "freetube",
"productName": "FreeTube",
"description": "A private YouTube client",
"version": "0.17.1",
"version": "0.18.0",
"license": "AGPL-3.0-or-later",
"main": "./dist/main.js",
"private": true,
Expand Down Expand Up @@ -35,12 +35,11 @@
"dev-runner": "node _scripts/dev-runner.js",
"lint-fix": "eslint --fix --ext .js,.vue ./",
"lint": "eslint --ext .js,.vue ./",
"pack": "run-p pack:main pack:renderer pack:workers",
"pack": "run-p pack:main pack:renderer",
"pack:browser": "webpack --mode=production --node-env=production --config _scripts/webpack.renderer.browser.config.js",
"pack:main": "webpack --mode=production --node-env=production --config _scripts/webpack.main.config.js",
"pack:renderer": "webpack --mode=production --node-env=production --config _scripts/webpack.renderer.config.js",
"pack:web": "webpack --mode=production --node-env=production --config _scripts/webpack.web.config.js",
"pack:workers": "webpack --mode=production --node-env=production --config _scripts/webpack.workers.config.js",
"postinstall": "yarn run --silent rebuild:electron",
"prettier": "prettier --write \"{src,_scripts}/**/*.{js,vue}\"",
"rebuild:electron": "electron-builder install-app-deps",
Expand All @@ -58,46 +57,45 @@
"@silvermine/videojs-quality-selector": "^1.2.5",
"autolinker": "^4.0.0",
"browserify": "^17.0.0",
"browserify-zlib": "^0.2.0",
"electron-context-menu": "^3.5.0",
"http-proxy-agent": "^5.0.0",
"https-proxy-agent": "^5.0.0",
"lodash.debounce": "^4.0.8",
"lodash.isequal": "^4.5.0",
"marked": "^4.1.1",
"nedb-promises": "^6.2.1",
"opml-to-json": "^1.0.1",
"process": "^0.11.10",
"socks-proxy-agent": "^6.0.0",
"socks-proxy-agent": "^7.0.0",
"video.js": "7.18.1",
"videojs-contrib-quality-levels": "^2.1.0",
"videojs-http-source-selector": "^1.1.6",
"videojs-mobile-ui": "^0.8.0",
"videojs-overlay": "^2.1.4",
"videojs-vtt-thumbnails-freetube": "0.0.15",
"vue": "^2.7.13",
"vue-i18n": "^8.27.2",
"vue-i18n": "^8.28.1",
"vue-observe-visibility": "^1.0.0",
"vue-router": "^3.6.5",
"vuex": "^3.6.2",
"youtube-suggest": "^1.2.0",
"yt-channel-info": "^3.1.1",
"yt-channel-info": "^3.2.1",
"yt-dash-manifest-generator": "1.1.0",
"ytdl-core": "^4.11.2",
"ytdl-core": "https://github.com/absidue/node-ytdl-core#fix-likes-extraction",
"ytpl": "^2.3.0",
"ytsr": "^3.8.0"
},
"devDependencies": {
"@babel/core": "^7.18.13",
"@babel/core": "^7.20.2",
"@babel/plugin-proposal-class-properties": "^7.18.6",
"@babel/preset-env": "^7.18.10",
"archiver": "^5.3.1",
"babel-eslint": "^10.1.0",
"babel-loader": "^8.2.5",
"babel-loader": "^9.1.0",
"copy-webpack-plugin": "^11.0.0",
"cordova": "^11.0.0",
"css-loader": "^6.7.1",
"css-loader": "^6.7.2",
"css-minimizer-webpack-plugin": "^4.2.2",
"electron": "^21.1.1",
"electron": "^21.2.3",
"electron-builder": "^23.6.0",
"eslint": "^7.32.0",
"eslint-config-prettier": "^8.3.0",
Expand All @@ -107,22 +105,22 @@
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-promise": "^5.1.0",
"eslint-plugin-standard": "^5.0.0",
"eslint-plugin-vue": "^9.6.0",
"eslint-plugin-vue": "^9.7.0",
"html-webpack-plugin": "^5.3.2",
"js-yaml": "^4.1.0",
"json-minimizer-webpack-plugin": "^4.0.0",
"lefthook": "^1.1.3",
"mini-css-extract-plugin": "^2.6.1",
"npm-run-all": "https://github.com/MarmadileManteater/npm-run-all.git",
"lefthook": "^1.1.4",
"mini-css-extract-plugin": "^2.7.0",
"npm-run-all": "^4.1.5",
"prettier": "^2.7.1",
"rimraf": "^3.0.2",
"sass": "^1.54.9",
"sass-loader": "^13.0.2",
"sass": "^1.56.0",
"sass-loader": "^13.2.0",
"tree-kill": "1.2.2",
"vue-devtools": "^5.1.4",
"vue-eslint-parser": "^9.1.0",
"vue-loader": "^15.10.0",
"webpack": "^5.74.0",
"webpack": "^5.75.0",
"webpack-cli": "^4.10.0",
"webpack-dev-server": "^4.11.1",
"xml2js": "^0.4.23"
Expand Down
Loading

0 comments on commit 263d158

Please sign in to comment.