aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFiles
13 daysUpgrade to runcap v1.4HEADmasterSergey Poznyakoff1
2024-03-13Minor changesSergey Poznyakoff1
2024-03-13Document foreign destination handlingSergey Poznyakoff3
2024-03-13Update copyright years and version numberSergey Poznyakoff43
2024-03-13Gracious handling of foreign destination directoriesSergey Poznyakoff14
Destination directory is "foreign" if it is not a checkout (clone) of the VCS that invoked a hook trying to update it. By default, encountering such directory aborts the update with the corresponding error message. This handling can be changed by setting the foreign-dir-mode configuration setting to one of the following values: error bail out; this is the default remove remove the offending directory and check it out from the VCS. rename rename the offending directory and proceed with the checkout. archive archive the offending directory, remove it and then proceed with the checkout. * src/Makefile.am: Add new sources. * src/checkdir.c: New file. * src/rmhier.c: New file. * src/config.c (cb_syslog_facility): "none" disables syslog. (vcsync_config_kw, vcsync_kw): New keywords: foreign-dir-mode, archive-command. (config_finish): Require that archive-command be set if foreign-dir-mode is "archive". * src/cvs.c (cvs_proc): Rewrite using check_output_dir. (cvs_dir_ok): New function. * src/git.c (git_proc): Rewrite using check_output_dir. (git_dir_ok): New function. * src/svn.c (svn_proc): Rewrite using check_output_dir. (svn_dir_ok): New function. * src/vcsync.c (vcs_tab): Change definition. (vcs_proc_get): Replace with vcs_defn_get. All uses changed. (vcsync_check_sentinel): Removed. * src/vcsync.h (vcs_defn): New struct. (vcsync_config): Replace proc with vcs; all uses changed. (vcsync_config): New fields: foreign_dir_mode, archive_command. (vcs_defn_get, cvs_dir_ok, svn_dir_ok, git_dir_ok): New protos. (VCSYNC_MODE): New data type. (FOREIGN_DIR_ERROR, FOREIGN_DIR_REMOVE) (FOREIGN_DIR_RENAME, FOREIGN_DIR_ARCHIVE): New constants. (remove_hier, check_output_dir): New protos. * tests/Makefile.am: Add new tests. * tests/testsuite.at: Add new tests. * tests/cvsfor.at: New test. * tests/gitfor.at: New test. * tests/svnfor.at: New test.
2023-06-02Fix testsuiteSergey Poznyakoff2
2023-06-02Upgrade grecsSergey Poznyakoff4
2021-02-18Version 1.3v1.3Sergey Poznyakoff2
2021-02-18Implement the sentinel file. Write texinfo documentation (finally).Sergey Poznyakoff21
* src/config.c: New statement: sentinel. * src/cvs.c (cvs_proc): Call vcsync_check_sentinel. * src/git.c (git_proc): Likewise. * src/svn.c (svn_proc): Likewise. * src/vcsync.c (vcsync_check_sentinel): New function. * src/vcsync.h (vcsync_config): New member: sentinel_file. (vcsync_check_sentinel): New proto. * tests/Makefile.am: Add new tests. * tests/testsuite.at: Likewise. * tests/cvssent.at: New test. * tests/gitsent.at: New test. * tests/svnsent.at: New test. * README: Add pointers to the documentation. * doc/Makefile.am: Build texinfo docs. * doc/gendocs.pl: New file. * doc/grecs-syntax.texi: New file. * doc/otherdoc.texi: New file. * doc/vcsync.8: Add the NOTE section. * doc/vcsync.conf.5: Likewise. * doc/vcsync.texi: Complete documentation. * doc/webdoc.init: New file. * doc/otherdoc.texi.in: New file.
2021-02-16Version 1.2v1.2Sergey Poznyakoff3
2020-06-14Use grecs with wordsplit v1.1Sergey Poznyakoff1
2019-08-16Upgrade runcap.Sergey Poznyakoff2
* runcap: Upgrade. * src/runcmd.c: Disable unneeded capturing.
2019-08-15Use runcap to run external programsSergey Poznyakoff12
* .gitmodules (runcap): New submodule. * Makefile.am: Incorporate runcap. * src/Makefile.am: Likewise. * src/runcmd.c: Rewrite using runcap. * src/git.c: Use new runcmd functions. * src/svn.c: Likewise. * src/vcsync.c: Remove unneded call to sigsetup. * src/vcsync.h: Update. * NEWS: Update. * configure.ac: Version 1.1.90
2019-08-13Version 1.1v1.1Sergey Poznyakoff2
2019-08-13Minor changesSergey Poznyakoff1
* src/config.c: Use grecs assertion functions instead of local wrappers. (config_finish): If vcs_type is specified, try to select a matching named configuration first, even if the default one has the vcs-type statement.
2019-08-10Don't descend into internal VCS directories. Fix early diagnostics.Sergey Poznyakoff5
* src/checkoutrc.c: Ignore internal VCS directories * src/config.c: Dont issue debug messages before logging is set up. * src/vcsync.c (main): Print diagnostic message about VCS type and configuration name. * tests/checkoutrc-rec.at: Fix expected stderr. * tests/checkoutrc.at: Likewise.
2019-08-09One more fixSergey Poznyakoff1
* src/onfig.c (config_finish): Select named configuration based on vcs_type, if given
2019-08-09BugfixeSergey Poznyakoff1
* src/config.c (vcsync_config_free): Remove unused function. (cb_config): Make sure config is not NULL.
2019-08-09Remove hardcoded destination directorySergey Poznyakoff1
2019-08-09Version 1.0.90Sergey Poznyakoff2
2019-08-09Implement automatic detection of the VCS used.Sergey Poznyakoff35
If vcsync binary is symlinked to the hooks subdirectory of a git or svn repository, it will detect the fact and will assume the corresponding VCS flavor (unless explicitly told otherwise). In this case the first named configuration that has the matching VCS type will be used. * src/config.c (cb_vcs_type): Set both vcs_type and proc. (cb_config): Build a singly-linked list of configurations. (vcsync_config_kw,vcsync_kw): Pass a pointer to struct vcsync_config. (config_finish): If vcs_type is not set, try to detect what VCS is used. * src/diag.c (fullprogname): New global. (setprogname): Set fullprogname. * src/git.c (get_cwd): Move to vcsync.c * src/vcsync.c (parsefilename,string_suffix) (get_cwd,guess_vcs_type): New functions. * src/vcsync.h (fullprogname): New extern. (vcs_type): Remove const qualifier. (parsefilename,string_suffix) (get_cwd,guess_vcs_type,vdiag): New protos. * src/checkoutrc.c: Shut up gcc warning. * src/runcmd.c: Likewise. * src/svn.c: Likewise. * tests/checkoutrc-rec.at: Account for additional debug message. * tests/checkoutrc.at: Likewise. * tests/cvscom00.at: Account for eventual debug messages. * tests/cvscom01.at: Likewise. * tests/cvscom02.at: Likewise. * tests/cvscom03.at: Likewise. * tests/cvscom04.at: Likewise. * tests/cvsimp.at: Likewise. * tests/cvsimp01.at: Likewise. * tests/gitimp.at: Likewise. * tests/gitimp01.at: Likewise. * tests/gitpush00.at: Likewise. * tests/gitpush01.at: Likewise. * tests/gitpush02.at: Likewise. * tests/gitpush03.at: Likewise. * tests/namedconf00.at: Likewise. * tests/svncom00.at: Likewise. * tests/svncom01.at: Likewise. * tests/svncom02.at: Likewise. * tests/svncom03.at: Likewise. * tests/svncom04.at: Likewise. * tests/svnimp.at: Likewise. * tests/svnimp01.at: Likewise.
2019-07-24Further fixes in the testsuiteSergey Poznyakoff6
* tests/svncom00.at: Fix typo. * tests/svncom01.at: Likewise. * tests/svncom02.at: Likewise. * tests/svncom03.at: Likewise. * tests/svncom04.at: Likewise. * tests/testsuite.at (AT_NONROOT_PREREQ): New macro. (AT_VCS_PREREQ): Use AT_NONROOT_PREREQ for CVS.
2019-07-24Improve testsuiteSergey Poznyakoff2
Take into account version differences in CVS and GIT * tests/atlocal.in (CVS_FORMAT): New variable. * tests/testsuite.at (CVS_REPO_INIT): Use CVS_FORMAT when forming template string. (GIT_COM_INIT): Set user.email and user.name.
2019-07-24Version 1.0v1.0Sergey Poznyakoff8
2019-07-20Add bootstrapSergey Poznyakoff1
2019-07-20Update grecsSergey Poznyakoff6
2016-06-09Adopt for using new CVS format strings.Sergey Poznyakoff3
* src/cvs.c (cvs_proc): Drain input as recommended by the CVS docs. Handle multiple arguments. * src/vcsync.c (main): Don't close descriptors when forking. * doc/vcsync.8: Update.
2014-06-08Implement socket notification (tcpmux-plus)Sergey Poznyakoff3
* src/checkoutrc.c (post_socket_send): New function. (flush_checkoutrc_files): Call post_socket_send * src/config.c: New statements post-sync-socket and post-sync-tag. * src/vcsync.h (vcsync_sockaddr): New struct. (vcsync_config) <post_sync_socket> <post_sync_tag>: New members.
2014-03-10Make access file creation more configurableSergey Poznyakoff5
* doc/vcsync.conf.5: Update. * src/checkoutrc.c (access_file_name) (access_file_text): New globals. (open_htaccess): Write access_file_text to the newly created file. (write_htaccess,kwf_unlink): Use access_file_name instead of the hardcoded HTACCESS_FILE. (checkoutrc): Likewise. Initialize access_file_name, if it is not defined. * src/config.c: New statements access-file-name and access-file-text * src/vcsync.h (access_file_name,access_file_text): New externs. * tests/checkoutrc.at: Test access-file-text.
2014-03-07Minor fix.Sergey Poznyakoff1
* src/checkoutrc.c (kwf_unlink): Use lstat.
2014-03-07Allow admins to define new .checkoutrc keywords.Sergey Poznyakoff12
* Makefile.am: Add distuninstallcheck_listfiles. * src/Makefile.am (EXTRA_DIST): Add vcsync.conf (install-data-local): New rule. * src/vcsync.conf: New file. * src/checkoutrc.c (kwtab): Set fixed size. Remove all verbatim and text keywords. These should be defined in the configuration file. * src/config.c: New statement "define". * src/vcsync.h (MAX_CHECKOUTRC_KW): New define. * tests/atlocal.in (DFL_VCSYNC_CONF): New variable. * tests/checkoutrc-rec.at: Use ../src/vcsync.conf * tests/checkoutrc.at: Likewise. * tests/testsuite.at: Include src/vcsync.conf in all configuration files. * doc/vcsync.8: Update. * doc/vcsync.conf.5: Document the "define" statement.
2014-03-06Implement "ssi" checkoutrc statement.Sergey Poznyakoff2
2014-03-06Bugfixes.Sergey Poznyakoff5
* doc/vcsync.texi: Update. * src/checkoutrc.c (kwf_link): Always try unlinking the target file. (kwf_chmod): Take one or more file arguments. Allow for wildcards. (flush_checkoutrc_files): Don't check for presence of checkoutrc file, register the directory anyway (to make sure it is descended into). * src/cvs.c (split_arg): Fix return value. * src/vcsync.c (main): Print message on the stderr. * tests/cvsimp.at: Use CVS_COM_INIT macro.
2014-03-05BugfixSergey Poznyakoff1
* src/checkoutrc.c (write_htaccess): Create a copy of ap for debugging purposes.
2014-03-05Minor fix in the testsuiteSergey Poznyakoff1
2014-03-05Raise version to 0.90.91Sergey Poznyakoff2
2014-03-05Fix typosSergey Poznyakoff2
2014-03-05Minor changes.Sergey Poznyakoff2
* src/cvs.c (cvs_proc): Change diag to debug. * tests/testsuite.at: Set debug statement from the VCSYNC_TESTSUITE_DEBUG environment variable.
2014-03-05Add manpages.Sergey Poznyakoff3
2014-03-05Rename doinstrc to checkoutrcSergey Poznyakoff19
2014-03-05Minor changes.Sergey Poznyakoff4
* src/cmdline.opt: Group options by functionality in the help output. New options: --vcs-type, --detach, --sleep. * src/config.c: Take into account new options. * src/vcsync.c (sleep_option,detach_option) (vcs_type): New variables. * src/vcsync.h (sleep_option,detach_option) (vcs_type): New protos.
2014-03-04Implement the unlink action.Sergey Poznyakoff1
2014-03-04Add doc/.gitignoreSergey Poznyakoff1
2014-03-04Fix handling of doinstrc files.Sergey Poznyakoff18
* src/cvs.c (cvs_proc): Return directory under dist_root to change to. * src/git.c (git_proc): Likewise. * src/svn.c (svn_proc): Likewise. * src/doinstrc.c (doinstrc): Take root dir as first argument. Build all paths by concatenating dest_root, root_dir, directory and the file in question. If root_dir is NULL, it is ignored. (flush_doinstrc_files): Take root dir as first argument. * src/vcsync.c (main): Pass return value from config->proc to flush_doinstrc_files. * src/vcsync.h (vcs_proc_fn): Return char *. (cvs_proc, svn_proc, git_proc): Change prototype accordingly. * tests/Makefile.am: Add new files. * tests/testsuite.at: Include new testcases. (CVS_REPO_INIT,SVN_REPO_INIT) (GIT_REPO_INIT): Take optional argument. * tests/cvscom03.at: New file. * tests/cvscom04.at: New file. * tests/cvsimp01.at: New file. * tests/gitimp01.at: New file. * tests/gitpush03.at: New file. * tests/svncom03.at: New file. * tests/svncom04.at: New file. * tests/svnimp01.at: New file. * tests/doinstrc-rec.at: Fix keywords. * tests/doinstrc.at: Likewise.
2014-03-03Reword test descriptions.Sergey Poznyakoff4
2014-03-03Add two more SVN tests.Sergey Poznyakoff4
2014-03-03Remove repository-root statement and -R command line option.Sergey Poznyakoff11
* src/cmdline.opt: Remove the --repository-root (-R) option. * src/config.c: Remove the repository-root statement. * src/cvs.c (cvs_proc): Get the repository path from the CVSROOT envar. * src/vcsync.c (repository_root,repo_name): Remove. * src/vcsync.h (repository_root,repo_name): Remove. (vcsync_config)<repo_root>: Remove. * tests/cvsimp.at: Reflect the changes. * tests/doinstrc-rec.at: Likewise. * tests/doinstrc.at: Likewise. * tests/namedconf00.at: Likewise. * tests/testsuite.at: Likewise. * doc/vcsync.texi: Update.
2014-03-03Implement git support.Sergey Poznyakoff14
* src/Makefile.am (vcsync_SOURCES): Add git.c * src/git.c: New file. * src/runcmd.c (runcmd): Use /dev/null for stdin. * src/vcsync.c (vcs_tab): Add entry for git. * src/vcsync.h (git_proc): New proto. * tests/gitimp.at: New file. * tests/gitpush00.at: New file. * tests/gitpush01.at: New file. * tests/gitpush02.at: New file. * tests/Makefile.am: Add new files. * tests/testsuite.at: Likewise. * tests/cvscom01.at: Minor change.
2014-02-28BugfixSergey Poznyakoff1
2014-02-28Complement previous commitSergey Poznyakoff11

Return to:

Send suggestions and report system problems to the System administrator.