Skip to content

Commit

Permalink
Merge pull request #86 from owncloud/chore/linter-dependencies-depend…
Browse files Browse the repository at this point in the history
…abot-codeowners

Update linting, upgrade dependencies, add dependabot, update codeowners
  • Loading branch information
Pascal Wengerter authored Oct 12, 2021
2 parents 2ce6b5c + 83c8033 commit 567cc50
Show file tree
Hide file tree
Showing 26 changed files with 1,888 additions and 1,821 deletions.
12 changes: 0 additions & 12 deletions .drone.star
Original file line number Diff line number Diff line change
Expand Up @@ -56,23 +56,20 @@ def changelog(ctx):
{
'name': 'generate',
'image': 'toolhippie/calens:latest',
'pull': 'always',
'commands': [
'calens >| CHANGELOG.md',
],
},
{
'name': 'diff',
'image': 'owncloudci/alpine:latest',
'pull': 'always',
'commands': [
'git diff',
],
},
{
'name': 'output',
'image': 'owncloudci/alpine:latest',
'pull': 'always',
'commands': [
'cat CHANGELOG.md',
],
Expand Down Expand Up @@ -246,15 +243,13 @@ def tests(ctx):
{
'name': 'install',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn install --frozen-lockfile',
],
},
{
'name': 'lint',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn lint',
],
Expand All @@ -263,7 +258,6 @@ def tests(ctx):
{
'name': 'build',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn build',
],
Expand All @@ -272,7 +266,6 @@ def tests(ctx):
{
'name': 'unit',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn test:unit'
],
Expand All @@ -281,7 +274,6 @@ def tests(ctx):
{
'name': 'integration',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn test:integration'
],
Expand Down Expand Up @@ -311,7 +303,6 @@ def release(ctx):
{
'name': 'build',
'image': 'owncloudci/nodejs:14',
'pull': 'always',
'commands': [
'yarn install --frozen-lockfile',
'yarn build'
Expand All @@ -325,7 +316,6 @@ def release(ctx):
{
'name': 'changelog',
'image': 'toolhippie/calens:latest',
'pull': 'always',
'commands': [
'calens --version %s -o dist/CHANGELOG.md' % ctx.build.ref.replace("refs/tags/v", "").split("-")[0],
],
Expand All @@ -338,7 +328,6 @@ def release(ctx):
{
'name': 'publish-github',
'image': 'plugins/github-release:latest',
'pull': 'always',
'settings': {
'api_key': {
'from_secret': 'github_token',
Expand All @@ -356,7 +345,6 @@ def release(ctx):
{
'name': 'publish-npm',
'image': 'plugins/npm:latest',
'pull': 'always',
'settings': {
'username': {
'from_secret': 'npm_username',
Expand Down
10 changes: 7 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,21 @@ module.exports = {
},
extends: ['plugin:vue/recommended', 'eslint:recommended', '@vue/prettier'],
parserOptions: {
parser: "@babel/eslint-parser",
parser: '@babel/eslint-parser',
ecmaVersion: 6,
sourceType: "module"
sourceType: 'module'
},
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off'
},
overrides: [
{
files: ['**/__tests__/*.{j,t}s?(x)', '**/tests/unit/**/*.spec.{j,t}s?(x)', '**/tests/integration/**/*.spec.{j,t}s?(x)'],
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)',
'**/tests/integration/**/*.spec.{j,t}s?(x)'
],
env: {
jest: true
}
Expand Down
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* LukasHirt
* @kulmann @pascalwengerter @fschade @paulcod3
10 changes: 10 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: weekly
day: "monday"
labels:
- "Status:Needs-Review"
- "Topic:Dependencies"
5 changes: 3 additions & 2 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"printWidth": 100,
"semi": false,
"singleQuote": true
}
"singleQuote": true,
"trailingComma": "none"
}
5 changes: 5 additions & 0 deletions changelog/unreleased/bugfix-update-dependencies
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Bugfix: Update dependencies

We've updated some of this project's dependencies.

https://github.com/owncloud/file-picker/pull/86
8 changes: 4 additions & 4 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ module.exports = {
'<rootDir>/src/**/*.{vue, js}',
'!<rootDir>/src/main.js',
'!<rootDir>/src/services/auth.js',
'!<rootDir>/src/assets/**/*',
'!<rootDir>/src/assets/**/*'
],
coverageDirectory: '<rootDir>/coverage',
moduleFileExtensions: ['js', 'vue'],
moduleNameMapper: {
'^@/(.*)$': '<rootDir>/src/$1',
'^.+\\.(css|scss)$': 'babel-jest',
'^.+\\.(css|scss)$': 'babel-jest'
},
modulePaths: ['<rootDir>'],
rootDir: path.resolve(__dirname, './'),
Expand All @@ -31,7 +31,7 @@ module.exports = {
'^.+\\.js$': 'babel-jest',
'^.+\\.vue$': 'vue-jest',
'^.+\\.(jpg|ico|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
'<rootDir>/__mocks__/file.js',
'<rootDir>/__mocks__/file.js'
},
transformIgnorePatterns: ['node_modules/(?!lodash-es/.*)'],
transformIgnorePatterns: ['node_modules/(?!lodash-es/.*)']
}
10 changes: 8 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,17 @@
"oidc-client": "^1.11.5",
"owncloud-design-system": "^7.2.0",
"owncloud-sdk": "^1.0.0-2296",
"postcss-import": "^12.0.1",
"postcss-url": "^9.0.0",
"tippy.js": "^6.3.1",
"uikit": "3.5.16",
"vue-avatar": "^2.3.3",
"vue-datetime": "^1.0.0-beta.14",
"vue-gettext": "^2.1.12",
"vue-inline-svg": "^2.0.0",
"vue-select": "^3.11.2"
"vue-select": "^3.11.2",
"webfontloader": "^1.6.28",
"weekstart": "^1.0.0"
},
"devDependencies": {
"@babel/core": "^7.13.16",
Expand Down Expand Up @@ -81,6 +85,8 @@
"vue": "^2.6.12",
"vue-jest": "^3.0.7",
"vue-loader": "^15.9.6",
"vue-template-compiler": "^2.6.12"
"vue-template-compiler": "^2.6.12",
"webpack": "^4.0.0"
}
}

44 changes: 22 additions & 22 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,15 +53,15 @@ if (!Vue.prototype.$gettext) {
cs: 'Czech',
fr: 'Français',
it: 'Italiano',
gl: 'Galego',
gl: 'Galego'
}
const translations = merge({}, filePickerTranslations, odsTranslations)
Vue.use(VueGettext, {
availableLanguages: supportedLanguages,
defaultLanguage: navigator.language.substring(0, 2),
translations,
silent: true,
silent: true
})
}
Expand All @@ -70,77 +70,77 @@ export default {
components: {
FilePicker,
Login,
Login
},
props: {
variation: {
type: String,
required: true,
validator: (value) => value === 'resource' || value === 'location',
validator: (value) => value === 'resource' || value === 'location'
},
configLocation: {
type: String,
required: false,
default: () => window.location.origin + '/file-picker-config.json',
default: () => window.location.origin + '/file-picker-config.json'
},
bearerToken: {
type: String,
required: false,
default: null,
default: null
},
configObject: {
type: [Object, String],
required: false,
default: null,
default: null
},
isSdkProvided: {
type: Boolean,
required: false,
default: false,
default: false
},
selectBtnLabel: {
type: String,
required: false,
default: null,
default: null
},
isSelectBtnDisplayed: {
type: Boolean,
required: false,
default: true,
default: true
},
cancelBtnLabel: {
type: String,
required: false,
default: null,
default: null
},
isOdsProvided: {
type: Boolean,
required: false,
default: false,
default: false
},
locale: {
type: String,
required: false,
default: null,
default: null
},
isInitialFocusEnabled: {
type: Boolean,
required: false,
default: false,
},
default: false
}
},
data: () => ({
authInstance: null,
state: 'loading',
config: null,
config: null
}),
computed: {
currentLocale() {
return this.locale || navigator.language.substring(0, 2)
},
}
},
created() {
Expand Down Expand Up @@ -169,11 +169,11 @@ export default {
this.$client.init({
baseUrl: this.config.server,
auth: {
bearer: bearerToken,
bearer: bearerToken
},
headers: {
'X-Requested-With': 'XMLHttpRequest',
},
'X-Requested-With': 'XMLHttpRequest'
}
})
}
Expand Down Expand Up @@ -226,8 +226,8 @@ export default {
onFolderLoaded(folder) {
this.$emit('folderLoaded', folder)
},
},
}
}
}
</script>

Expand Down
Loading

0 comments on commit 567cc50

Please sign in to comment.