import marc file into dspace

download this script from github

https://github.com/amdmaher/import-marc-into-dspace

1- check the marcĀ file

2- run mk2dc.pl to convert from mrc to dubline core
./mk2dc.pl 762.mrc > 762.xml

3- create import dir

mkdir import

4- run build.pl to build dspace file folders

this ./build.pl 762.xml
5- now import records to dspace
./dspace import -a -e email@mail.com -c [CollectionID] -s import -m mapfile

Advertisements

difference between .CGI and .PL

.pl is the standard Perl extension.

.pl just to indicate it’s written in Perl

.pl files are executed from a unix command line

.cgi is the standard extension for CGI executables

.cgi files are executed by a web server

Both could have the exact same code inside.

more..

the cgi extention can really be anything, it all depends on the way the HTTP server was configured to run scripts(ScriptAlias)

cgi script file does not have to be just perl, it can be shell script, or C program

 

Create perl binaries from perl scripts

we can convert perl script to binary using

perlcc command in a simple way

First let us generate a perl script, create a file call hello

#!/usr/bin/perl
print "hello world. ";

Convert it into executable,

chmod +x hello

Try to run it, that is our normal perl script. To make it as a binary with ELF header, do this

perlcc -o hello-bin hello
now run ./hello-bin