Giter VIP home page Giter VIP logo

imgcp's Introduction

imgcp

imgcp is a command line tool that allows to copy files between old disk images (floppies, hard drives, archive files, etc). Currently supported formats are:

  • CD images (CUE/BIN, MDS/MDF) (read only)
  • FAT12
  • FAT16
  • Interchange File Format (IFF) files (read only)
  • ISO 9660 (read only)

Apart from copying files, imgcp also implements other useful operations:

  • cat: Similar to the UNIX cat command, it can be used to print on the standard output the concatenation of several files inside disk images.
  • ls: Similar to the UNIX ls command, it can be used to explore the content of an image.
  • mkdir: To create empty directories.
  • remove: To remove files and directories.
  • show: The default operation. It shows basic information of the input images.

Installing imgcp

First get the repository:

git clone https://github.com/adriagipas/imgcp.git
cd imgcp

Then install the software using the go command:

go build
go install

This will install imgcp to your standard Go install directory. If you want to change the standard directory please refer to the official compile-install tutorial

Examples

Print basic version and usage information:

imgcp

Print basic information of a hard drive image (hdd.img):

imgcp hdd.img

List the contents of the first partition of a hard drive image (hdd.img):

imgcp hdd.img ls /0

List the contents of the DOS folder in the first partition of a hard drive image (hdd.img):

imgcp hdd.img ls /0/DOS

Concatenate the content of AUTOEXEC.BAT and CONFIG.SYS files from first partition of hdd.img:

imgcp hdd.img cat /0/autoexec.bat /0/config.sys

In the previous hard drive image, copy AUTOEXEC.BAT as "AUTOCOP.BAT" to a new empty folder FOO:

imgcp hdd.img mkdir /0/foo
imgcp hdd.img cp /0/autoexec.bat /0/foo/autocop.bat

In previous folder FOO, copy CONFIG.SYS and DOS folder:

imgcp hdd.img cp /0/config.sys /0/DOS /0/foo/

Copy the content of an old floppy image (floppy.img) into folder DISK in the first partition of hdd.img:

imgcp hdd.img mkdir /0/DISK
imgcp A=hdd.img B=floppy.img cp B=/ A=/0/DISK

Remove FOO and DISK folders from previous examples:

imgcp hdd.img rm /0/disk /0/foo

Copy the content of an old floppy image (floppy.image) into a local folder /tmp/disk:

mkdir -p /tmp/disk
imgcp A=floppy.img B=/ cp A=/ B=/tmp/disk/

Copy previous folder /tmp/disk into the first partition of hdd.img:

imgcp A=hdd.img B=/ cp B=/tmp/disk A=/0/

imgcp's People

Contributors

adriagipas avatar

Stargazers

Gonçal Garcés Díaz-Munío avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.