Blame view

ingester/ingest.sh 527 Bytes
9d00822b4   Paulo Gra├ža   Initial commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
  #!/bin/bash
  
  # find all PDF files
  # find . -type f -name '*.pdf' -exec ./ingest.sh {} \;
  
  while [[ $# > 1 ]]
  do
      echo $1
      shift # past argument or value
  done
  
  mylogger() {
    echo "$(date +%F\ %H:%M:%S:%N): $@"
  }
  
  
  mylogger "start ingesting DOI from PDF: $file"
  
  # Ingest
  # based on DSPACE doc - https://wiki.duraspace.org/display/DSDOC18/Importing+and+Exporting+Items+via+Simple+Archive+Format
  /dspace/bin/dspace import --add --eperson=sama-saw@asa.fccn.pt --collection=10400.25/300 --source=/tmp/test --mapfile=mapfile1