aboutsummaryrefslogtreecommitdiff
path: root/multihome.c
Commit message (Collapse)AuthorAgeFilesLines
* Bug fixes:Joseph Hunkeler2021-06-201-13/+20
| | | | | * Allocate enough memory to handle a long host group name * Move "already_inside" check before host_group parsing
* Remove messages related to parsing configuration filesJoseph Hunkeler2021-06-171-3/+2
| | | | * Remove word "new" from creation message
* Fix host_group parser (#4)Joseph Hunkeler2021-06-161-29/+56
| | | | | * Do not segfault on invalid input * Report syntax errors * Ignore comments and inline comments
* Add shell init scripts and host_groups (#3)Joseph Hunkeler2021-06-161-68/+206
| | | | | | | | | | | | | | | | | | | * Add shell init scripts (templates) * Check for additional symbols * Handle missing PATH_MAX declaration (e.g. Ubuntu) * Install shell scripts into $PREFIX/share/init * Replace _INIT declaration with HOST_GROUP * Add scripts_dir and config_host_group struct elements to global 'multihome' * Fix count_substrings() returning wrong type * Refactor RSYNC_BIN to MULTIHOME_RSYNC_BIN * get_timestamp() no longer accepts a buffer as an argument * write_init_script() now uses scripts in $PREFIX/share/init/ to generate output files * Add user_host_group(), which allows grouping systems to a single home directory by way of regex pattern matching * strip_domainname() returns modified pointer, not new storage * Fix strip_domainname test * Create configuration directory if it does not exist * CI needs to install multihome and use the correct script * Always resolve argv[0] to absolute path
* Refactor headers and relocate testsJoseph Hunkeler2020-09-111-77/+19
|
* Add strip_domainname to test_mainJoseph Hunkeler2020-09-041-2/+16
|
* Add get_timestamp function; Find program handles paths to files too;Joseph Hunkeler2020-09-031-11/+40
|
* Clean up find_programJoseph Hunkeler2020-09-031-3/+5
|
* find_program() returns the absolute path if it begins with "./"Joseph Hunkeler2020-09-031-9/+19
|
* Add strip_domainname function; Add missing @param for copy functionJoseph Hunkeler2020-09-031-10/+26
|
* Improvements:Joseph Hunkeler2020-09-021-21/+38
| | | | | | | | * Added field_type and field_where to user_transfer() to make visually inspecting code easier * Applied new MULTIHOME_* defines * Generate blank transfer config during first-run * Change wording "inject" -> "pull" * Show path to transfer config
* Remove newlineJoseph Hunkeler2020-09-011-1/+0
|
* Use HOME_OLD set by the init script for update mode instead. More robustJoseph Hunkeler2020-09-011-10/+7
|
* set new path to old path in update modeJoseph Hunkeler2020-09-011-1/+8
|
* Actually ignore empty linesJoseph Hunkeler2020-09-011-1/+1
|
* Implement update modeJoseph Hunkeler2020-09-011-10/+33
|
* Get basename from program entrypoint instead of hardcoding the program nameJoseph Hunkeler2020-09-011-2/+6
|
* Implement find_programJoseph Hunkeler2020-09-011-9/+52
|
* And populate buf otherwiseJoseph Hunkeler2020-09-011-0/+2
|
* Only call realpath when path is relativeJoseph Hunkeler2020-09-011-3/+5
|
* Optimize abspath generationJoseph Hunkeler2020-09-011-6/+1
|
* Fix NULL hostnameJoseph Hunkeler2020-08-311-1/+1
|
* Fix empty multihome.config_transfer pathJoseph Hunkeler2020-08-311-1/+20
|
* Comment init scriptJoseph Hunkeler2020-08-311-1/+5
|
* Wrap test code in #ifdef/#endifJoseph Hunkeler2020-08-311-1/+10
|
* Disable line buffering; Implement basic tests; Fix mkdirs bug: do not ↵Joseph Hunkeler2020-08-311-18/+106
| | | | prepend "/" to path
* Allow change to home rootJoseph Hunkeler2020-08-311-3/+13
|
* Handle some possible home directory errors. Fix topdir symlink to point to ↵Joseph Hunkeler2020-08-301-3/+17
| | | | the correct place.
* Refuse to nestJoseph Hunkeler2020-08-301-0/+7
|
* Fix accidental text replacementJoseph Hunkeler2020-08-301-3/+3
|
* Close transfer configJoseph Hunkeler2020-08-301-0/+1
|
* Use global tranfer configJoseph Hunkeler2020-08-301-6/+4
|
* Update multihome.cJoseph Hunkeler2020-08-301-4/+1
|
* Initial commitJoseph Hunkeler2020-08-301-0/+501