Skip to content

Commit 5c1101c

Browse files
authored
Merge branch 'DSpace:main' into DA-8586
2 parents e6065b7 + ffc5ecb commit 5c1101c

107 files changed

Lines changed: 9160 additions & 5177 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/pull_request_template.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
## References
22
_Add references/links to any related issues or PRs. These may include:_
3-
* Fixes #[issue-number]
4-
* Requires DSpace/DSpace#[pr-number] (if a REST API PR is required to test this)
3+
* Fixes #`issue-number` (if this fixes an issue ticket)
4+
* Requires DSpace/DSpace#`pr-number` (if a REST API PR is required to test this)
55

66
## Description
77
Short summary of changes (1-2 sentences).
@@ -19,8 +19,10 @@ List of changes in this PR:
1919
_This checklist provides a reminder of what we are going to look for when reviewing your PR. You need not complete this checklist prior to creating your PR (draft PRs are always welcome). If you are unsure about an item in the checklist, don't hesitate to ask. We're here to help!_
2020

2121
- [ ] My PR is small in size (e.g. less than 1,000 lines of code, not including comments & specs/tests), or I have provided reasons as to why that's not possible.
22-
- [ ] My PR passes [TSLint](https://palantir.github.io/tslint/) validation using `yarn run lint`
23-
- [ ] My PR doesn't introduce circular dependencies
22+
- [ ] My PR passes [ESLint](https://eslint.org/) validation using `yarn lint`
23+
- [ ] My PR doesn't introduce circular dependencies (verified via `yarn check-circ-deps`)
2424
- [ ] My PR includes [TypeDoc](https://typedoc.org/) comments for _all new (or modified) public methods and classes_. It also includes TypeDoc for large or complex private methods.
2525
- [ ] My PR passes all specs/tests and includes new/updated specs or tests based on the [Code Testing Guide](https://wiki.lyrasis.org/display/DSPACE/Code+Testing+Guide).
26-
- [ ] If my PR includes new, third-party dependencies (in `package.json`), I've made sure their licenses align with the [DSpace BSD License](https://github.com/DSpace/DSpace/blob/main/LICENSE) based on the [Licensing of Contributions](https://wiki.lyrasis.org/display/DSPACE/Code+Contribution+Guidelines#CodeContributionGuidelines-LicensingofContributions) documentation.
26+
- [ ] If my PR includes new libraries/dependencies (in `package.json`), I've made sure their licenses align with the [DSpace BSD License](https://github.com/DSpace/DSpace/blob/main/LICENSE) based on the [Licensing of Contributions](https://wiki.lyrasis.org/display/DSPACE/Code+Contribution+Guidelines#CodeContributionGuidelines-LicensingofContributions) documentation.
27+
- [ ] If my PR includes new features or configurations, I've provided basic technical documentation in the PR itself.
28+
- [ ] If my PR fixes an issue ticket, I've [linked them together](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue).

.github/workflows/build.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,19 @@ jobs:
1515
env:
1616
# The ci step will test the dspace-angular code against DSpace REST.
1717
# Direct that step to utilize a DSpace REST service that has been started in docker.
18-
DSPACE_REST_HOST: localhost
18+
DSPACE_REST_HOST: 127.0.0.1
1919
DSPACE_REST_PORT: 8080
2020
DSPACE_REST_NAMESPACE: '/server'
2121
DSPACE_REST_SSL: false
22+
# Spin up UI on 127.0.0.1 to avoid host resolution issues in e2e tests with Node 18+
23+
DSPACE_UI_HOST: 127.0.0.1
2224
# When Chrome version is specified, we pin to a specific version of Chrome
2325
# Comment this out to use the latest release
2426
#CHROME_VERSION: "90.0.4430.212-1"
2527
strategy:
2628
# Create a matrix of Node versions to test against (in parallel)
2729
matrix:
28-
node-version: [14.x, 16.x]
30+
node-version: [16.x, 18.x]
2931
# Do NOT exit immediately if one matrix job fails
3032
fail-fast: false
3133
# These are the actual CI steps to perform per job
@@ -112,7 +114,7 @@ jobs:
112114
start: yarn run serve:ssr
113115
# Wait for backend & frontend to be available
114116
# NOTE: We use the 'sites' REST endpoint to also ensure the database is ready
115-
wait-on: http://localhost:8080/server/api/core/sites, http://localhost:4000
117+
wait-on: http://127.0.0.1:8080/server/api/core/sites, http://127.0.0.1:4000
116118
# Wait for 2 mins max for everything to respond
117119
wait-on-timeout: 120
118120

@@ -147,7 +149,7 @@ jobs:
147149
run: |
148150
nohup yarn run serve:ssr &
149151
printf 'Waiting for app to start'
150-
until curl --output /dev/null --silent --head --fail http://localhost:4000/home; do
152+
until curl --output /dev/null --silent --head --fail http://127.0.0.1:4000/home; do
151153
printf '.'
152154
sleep 2
153155
done
@@ -158,7 +160,7 @@ jobs:
158160
# This step also prints entire HTML of homepage for easier debugging if grep fails.
159161
- name: Verify SSR (server-side rendering)
160162
run: |
161-
result=$(wget -O- -q http://localhost:4000/home)
163+
result=$(wget -O- -q http://127.0.0.1:4000/home)
162164
echo "$result"
163165
echo "$result" | grep -oE "<meta name=\"title\" [^>]*>" | grep DSpace
164166

.github/workflows/codescan.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# DSpace CodeQL code scanning configuration for GitHub
2+
# https://docs.github.com/en/code-security/code-scanning
3+
#
4+
# NOTE: Code scanning must be run separate from our default build.yml
5+
# because CodeQL requires a fresh build with all tests *disabled*.
6+
name: "Code Scanning"
7+
8+
# Run this code scan for all pushes / PRs to main branch. Also run once a week.
9+
on:
10+
push:
11+
branches: [ main ]
12+
pull_request:
13+
branches: [ main ]
14+
# Don't run if PR is only updating static documentation
15+
paths-ignore:
16+
- '**/*.md'
17+
- '**/*.txt'
18+
schedule:
19+
- cron: "37 0 * * 1"
20+
21+
jobs:
22+
analyze:
23+
name: Analyze Code
24+
runs-on: ubuntu-latest
25+
# Limit permissions of this GitHub action. Can only write to security-events
26+
permissions:
27+
actions: read
28+
contents: read
29+
security-events: write
30+
31+
steps:
32+
# https://github.com/actions/checkout
33+
- name: Checkout repository
34+
uses: actions/checkout@v3
35+
36+
# Initializes the CodeQL tools for scanning.
37+
# https://github.com/github/codeql-action
38+
- name: Initialize CodeQL
39+
uses: github/codeql-action/init@v2
40+
with:
41+
languages: javascript
42+
43+
# Autobuild attempts to build any compiled languages
44+
- name: Autobuild
45+
uses: github/codeql-action/autobuild@v2
46+
47+
# Perform GitHub Code Scanning.
48+
- name: Perform CodeQL Analysis
49+
uses: github/codeql-action/analyze@v2

CONTRIBUTING.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# How to Contribute
2+
3+
DSpace is a community built and supported project. We do not have a centralized development or support team, but have a dedicated group of volunteers who help us improve the software, documentation, resources, etc.
4+
5+
* [Contribute new code via a Pull Request](#contribute-new-code-via-a-pull-request)
6+
* [Contribute documentation](#contribute-documentation)
7+
* [Help others on mailing lists or Slack](#help-others-on-mailing-lists-or-slack)
8+
* [Join a working or interest group](#join-a-working-or-interest-group)
9+
10+
## Contribute new code via a Pull Request
11+
12+
We accept [GitHub Pull Requests (PRs)](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork) at any time from anyone.
13+
Contributors to each release are recognized in our [Release Notes](https://wiki.lyrasis.org/display/DSDOC7x/Release+Notes).
14+
15+
Code Contribution Checklist
16+
- [ ] PRs _should_ be smaller in size (ideally less than 1,000 lines of code, not including comments & tests)
17+
- [ ] PRs **must** pass [ESLint](https://eslint.org/) validation using `yarn lint`
18+
- [ ] PRs **must** not introduce circular dependencies (verified via `yarn check-circ-deps`)
19+
- [ ] PRs **must** include [TypeDoc](https://typedoc.org/) comments for _all new (or modified) public methods and classes_. Large or complex private methods should also have TypeDoc.
20+
- [ ] PRs **must** pass all automated pecs/tests and includes new/updated specs or tests based on the [Code Testing Guide](https://wiki.lyrasis.org/display/DSPACE/Code+Testing+Guide).
21+
- [ ] If a PR includes new libraries/dependencies (in `package.json`), then their software licenses **must** align with the [DSpace BSD License](https://github.com/DSpace/dspace-angular/blob/main/LICENSE) based on the [Licensing of Contributions](https://wiki.lyrasis.org/display/DSPACE/Code+Contribution+Guidelines#CodeContributionGuidelines-LicensingofContributions) documentation.
22+
- [ ] Basic technical documentation _should_ be provided for any new features or configuration, either in the PR itself or in the DSpace Wiki documentation.
23+
- [ ] If a PR fixes an issue ticket, please [link them together](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue).
24+
25+
Additional details on the code contribution process can be found in our [Code Contribution Guidelines](https://wiki.lyrasis.org/display/DSPACE/Code+Contribution+Guidelines)
26+
27+
## Contribute documentation
28+
29+
DSpace Documentation is a collaborative effort in a shared Wiki. The latest documentation is at https://wiki.lyrasis.org/display/DSDOC7x
30+
31+
If you find areas of the DSpace Documentation which you wish to improve, please request a Wiki account by emailing wikihelp@lyrasis.org.
32+
Once you have an account setup, contact @tdonohue (via [Slack](https://wiki.lyrasis.org/display/DSPACE/Slack) or email) for access to edit our Documentation.
33+
34+
## Help others on mailing lists or Slack
35+
36+
DSpace has our own [Slack](https://wiki.lyrasis.org/display/DSPACE/Slack) community and [Mailing Lists](https://wiki.lyrasis.org/display/DSPACE/Mailing+Lists) where discussions take place and questions are answered.
37+
Anyone is welcome to join and help others. We just ask you to follow our [Code of Conduct](https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx) (adopted via LYRASIS).
38+
39+
## Join a working or interest group
40+
41+
Most of the work in building/improving DSpace comes via [Working Groups](https://wiki.lyrasis.org/display/DSPACE/DSpace+Working+Groups) or [Interest Groups](https://wiki.lyrasis.org/display/DSPACE/DSpace+Interest+Groups).
42+
43+
All working/interest groups are open to anyone to join and participate. A few key groups to be aware of include:
44+
45+
* [DSpace 7 Working Group](https://wiki.lyrasis.org/display/DSPACE/DSpace+7+Working+Group) - This is the main (mostly volunteer) development team. We meet weekly to review our current development [project board](https://github.com/orgs/DSpace/projects), assigning tickets and/or PRs.
46+
* [DSpace Community Advisory Team (DCAT)](https://wiki.lyrasis.org/display/cmtygp/DSpace+Community+Advisory+Team) - This is an interest group for repository managers/administrators. We meet monthly to discuss DSpace, share tips & provide feedback back to developers.

Dockerfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
# This image will be published as dspace/dspace-angular
22
# See https://github.com/DSpace/dspace-angular/tree/main/docker for usage details
33

4-
FROM node:14-alpine
4+
FROM node:18-alpine
55
WORKDIR /app
66
ADD . /app/
77
EXPOSE 4000
88

9+
# Ensure Python and other build tools are available
10+
# These are needed to install some node modules, especially on linux/arm64
11+
RUN apk add --update python3 make g++ && rm -rf /var/cache/apk/*
12+
913
# We run yarn install with an increased network timeout (5min) to avoid "ESOCKETTIMEDOUT" errors from hub.docker.com
1014
# See, for example https://github.com/yarnpkg/yarn/issues/5540
1115
RUN yarn install --network-timeout 300000

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace
3535
Quick start
3636
-----------
3737

38-
**Ensure you're running [Node](https://nodejs.org) `v14.x` or `v16.x`, [npm](https://www.npmjs.com/) >= `v5.x` and [yarn](https://yarnpkg.com) == `v1.x`**
38+
**Ensure you're running [Node](https://nodejs.org) `v16.x` or `v18.x`, [npm](https://www.npmjs.com/) >= `v5.x` and [yarn](https://yarnpkg.com) == `v1.x`**
3939

4040
```bash
4141
# clone the repo
@@ -90,7 +90,7 @@ Requirements
9090
------------
9191

9292
- [Node.js](https://nodejs.org) and [yarn](https://yarnpkg.com)
93-
- Ensure you're running node `v14.x` or `v16.x` and yarn == `v1.x`
93+
- Ensure you're running node `v16.x` or `v18.x` and yarn == `v1.x`
9494

9595
If you have [`nvm`](https://github.com/creationix/nvm#install-script) or [`nvm-windows`](https://github.com/coreybutler/nvm-windows) installed, which is highly recommended, you can run `nvm install --lts && nvm use` to install and start using the latest Node LTS.
9696

@@ -379,10 +379,10 @@ To get the most out of TypeScript, you'll need a TypeScript-aware editor. We've
379379
- [Sublime Text](http://www.sublimetext.com/3)
380380
- [Typescript-Sublime-Plugin](https://github.com/Microsoft/Typescript-Sublime-plugin#installation)
381381
382-
Collaborating
382+
Contributing
383383
-------------
384384
385-
See [the guide on the wiki](https://wiki.lyrasis.org/display/DSPACE/DSpace+7+-+Angular+UI+Development#DSpace7-AngularUIDevelopment-Howtocontribute)
385+
See [Contributing documentation](CONTRIBUTING.md)
386386
387387
File Structure
388388
--------------

angular.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,10 @@
2525
}
2626
},
2727
"allowedCommonJsDependencies": [
28-
"angular2-text-mask",
2928
"cerialize",
3029
"core-js",
3130
"lodash",
3231
"jwt-decode",
33-
"url-parse",
3432
"uuid",
3533
"webfontloader",
3634
"zone.js"

config/config.example.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,9 @@ languages:
170170
- code: el
171171
label: Ελληνικά
172172
active: true
173+
- code: uk
174+
label: Yкраї́нська
175+
active: true
173176

174177
# Browse-By Pages
175178
browseBy:
@@ -207,6 +210,11 @@ item:
207210
undoTimeout: 10000 # 10 seconds
208211
# Show the item access status label in items lists
209212
showAccessStatuses: false
213+
bitstream:
214+
# Number of entries in the bitstream list in the item view page.
215+
# Rounded to the nearest size in the list of selectable sizes on the
216+
# settings menu. See pageSizeOptions in 'pagination-component-options.model.ts'.
217+
pageSize: 5
210218

211219
# Collection Page Config
212220
collection:
@@ -295,4 +303,4 @@ info:
295303
# display in supported metadata fields. By default, only dc.description.abstract is supported.
296304
markdown:
297305
enabled: false
298-
mathjax: false
306+
mathjax: false

cypress.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"screenshotsFolder": "cypress/screenshots",
66
"pluginsFile": "cypress/plugins/index.ts",
77
"fixturesFolder": "cypress/fixtures",
8-
"baseUrl": "http://localhost:4000",
8+
"baseUrl": "http://127.0.0.1:4000",
99
"retries": {
1010
"runMode": 2,
1111
"openMode": 0
@@ -22,4 +22,4 @@
2222
"DSPACE_TEST_SUBMIT_USER": "dspacedemo+submit@gmail.com",
2323
"DSPACE_TEST_SUBMIT_USER_PASSWORD": "dspace"
2424
}
25-
}
25+
}

docker/docker-compose-ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ services:
2424
# __D__ => "-" (e.g. google__D__metadata => google-metadata)
2525
# dspace.dir, dspace.server.url and dspace.ui.url
2626
dspace__P__dir: /dspace
27-
dspace__P__server__P__url: http://localhost:8080/server
28-
dspace__P__ui__P__url: http://localhost:4000
27+
dspace__P__server__P__url: http://127.0.0.1:8080/server
28+
dspace__P__ui__P__url: http://127.0.0.1:4000
2929
# db.url: Ensure we are using the 'dspacedb' image for our database
3030
db__P__url: 'jdbc:postgresql://dspacedb:5432/dspace'
3131
# solr.server: Ensure we are using the 'dspacesolr' image for Solr

0 commit comments

Comments
 (0)