A set of scripts that can be used to acquire and archive scanned documents.
sudo snap install document-imaging --edge
sudo snap connect document-imaging:raw-usb
Download the latest deb package from releases and install via commands:
sudo dpkg -i document-imaging.deb
sudo apt-get install -f
if the dependencies aren't already installedsudo dpkg -i document-imaging.deb
run install again, if dependencies were missin
sudo apt install ./document-imaging.deb
- Compile the code via
make
to build the document-imaging executable file - Build the docker image,
docker build -t docimg .
where docimg is the tag name, you can change that to whatever you'd like. - To run the images,
docker run --rm -t -i --device=/dev/bus/usb/001/009 -v $HOME/Documents/scan:/scan docimg
where docimg is the tag you picked in setup 1.
- To find the device path run
lsusb
, where 001 is the bus and 009 is the device
$ lsusb
Bus 001 Device 009: ID 04a9:1905 Canon, Inc. CanoScan LiDE 200
- The location on the host machine is included in the volume command in this case:
$HOME/Documents/scan
- You can add bash to the end of the run command to not stop the container after every run.
Now that you have document-imaging installed on your system. It's time to step the metadata configuration.
- See the
-h
flag for usage information - Usage the
-a "Your Name"
flag to configure author information
- This creates the metadata file in
$HOME/.config/document-imaging/metadata.json
or in the snap case$SNAP_USER_DATA/metadata.json
- The content should include the author information in json format;
{ author: "user" }
Run the script to start a docker container with all the tools needed for devlopment installed. It uses docker-compose to build and run the container and puts you into a shell for devlopment. The script is located in the root project directory, ./dev.sh
with $BUS
and $DEVICE
environment variables set. The values can be determined by running commands:
$ lsusb
Bus 001 Device 009: ID 04a9:1905 Canon, Inc. CanoScan LiDE 200
$ BUS=001 DEVICE=009 ./dev.sh
Install imagemagick
, libtiff-tools
, sane-utils
, devscripts
, and dh-make
on Ubuntu.