LinuxCommandLibrary

ci

Check in RCS revisions

TLDR

Check in a file and keep the working file unlocked

$ ci -u [path/to/file]
copy

Check in a file and keep the working file locked
$ ci -l [path/to/file]
copy

Check in a file with a specific log message
$ ci -m"[log_message]" [path/to/file]
copy

Check in a file, unlocking it but leaving the working file read-only
$ ci [path/to/file]
copy

Force check-in even if there are no changes
$ ci -f -u [path/to/file]
copy

SYNOPSIS

ci [options] file

PARAMETERS

-f, --force
    Force check-in, even if working file unchanged or locked by another.

-i
    Initial check-in; create RCS file from working file.

-l
    Local check-in: check-in and immediately check out writable version (locked).

-m msg
    Supply log message directly; suppresses prompt.

-rrev
    Insert revision at specific number or branch (default: next trunk).

-t[-]file
    Supply description from file (-t- reads stdin).

-u
    Check-in and unlock; leaves read-only copy.

-nrev
    Do not deposit revision but delete if default.

-q[level]
    Quiet mode; levels 1-3 reduce output.

-I
    Interactive mode; prompts for everything.

-j[lmrt]
    Join revisions (requires RCS 5.7+).

-ksubst
    Keyword expansion mode (e.g., -kkv for no subst).

-s state
    Set revision state.

-w login
    Override author login.

-d date
    Set revision date/time.

-R
    Recursive on directories (RCS 5.7+).

-T
    Enable strict locking.

DESCRIPTION

ci is the check-in command for the Revision Control System (RCS), a legacy version control tool. It records the current contents of a working file as a new revision (delta) in the corresponding RCS file (<filename,v), replacing the working file with the latest revision.

Typically, after editing a file checked out with co, use ci to store changes. It prompts for a log message describing the modification unless suppressed. Revisions form a tree or linear history, with deltas storing only changes.

ci supports symbolic names, states, and branches. It enforces locking to prevent concurrent modifications. Initial check-ins create RCS files from plain files. Widely used in 1980s-1990s Unix environments but largely replaced by CVS, Subversion, and Git. Still available on most Unix-like systems for legacy support.

CAVEATS

RCS uses ,v suffix files; incompatible with modern VCS. Locking can cause issues in multi-user setups. No network support; local only. Deprecated for new projects.

EXIT STATUS

0: success.
1: error (e.g., locked file).
2: fatal (no RCS file).

EXAMPLES

ci file.c   Prompt for message, check-in.
ci -u -m 'Bug fix' *.c   Unlock multiple.
ci -i -tDESC newfile   Initial with description.

HISTORY

Part of RCS, developed by Walter F. Tichy at Purdue University (1982). RCS 5 released 1990; GNU RCS enhancements later. Peaked in 1990s; declined with distributed VCS.

SEE ALSO

co(1), rcs(1), rlog(1), rcsdiff(1), merge(1)

Copied to clipboard