Add RC values, update docs, rename manpage
This commit is contained in:
@ -103,5 +103,5 @@ This allows connecting to older routers that require legacy SSH algorithms while
|
||||
## Documentation
|
||||
|
||||
- **[Detailed Documentation](docs/DETAILS.md)** - Complete feature guide, configuration reference, and examples
|
||||
- **[Manual Page](docs/router_backup.1)** - Unix manual page
|
||||
- **[Manual Page](docs/ipng-router-backup.1)** - Unix manual page
|
||||
- **[Changelog](debian/changelog)** - Version history and changes
|
||||
|
2
debian/rules
vendored
2
debian/rules
vendored
@ -18,7 +18,7 @@ override_dh_auto_install:
|
||||
mkdir -p debian/ipng-router-backup/usr/share/man/man1
|
||||
cp ipng-router-backup debian/ipng-router-backup/usr/bin/
|
||||
cp etc/* debian/ipng-router-backup/etc/ipng-router-backup/
|
||||
cp docs/router_backup.1 debian/ipng-router-backup/usr/share/man/man1/ipng-router-backup.1
|
||||
cp docs/ipng-router-backup.1 debian/ipng-router-backup/usr/share/man/man1/ipng-router-backup.1
|
||||
gzip debian/ipng-router-backup/usr/share/man/man1/ipng-router-backup.1
|
||||
|
||||
override_dh_auto_clean:
|
||||
|
@ -188,5 +188,7 @@ Software Version : v25.3.2
|
||||
- **Permission issues**: Verify SSH key permissions (600) and output directory access
|
||||
|
||||
### Exit Codes
|
||||
- `0`: Success
|
||||
- `1`: Configuration error, authentication failure, or connection issues
|
||||
- `0`: Success (all devices processed successfully)
|
||||
- `1`: Configuration error, authentication failure, or connection issues
|
||||
- `10`: Some devices failed
|
||||
- `11`: All devices failed
|
@ -98,10 +98,16 @@ Example configuration file
|
||||
.SH EXIT STATUS
|
||||
.TP
|
||||
.B 0
|
||||
Success
|
||||
Success (all devices processed successfully)
|
||||
.TP
|
||||
.B 1
|
||||
General error (configuration file not found, authentication failure, etc.)
|
||||
.TP
|
||||
.B 10
|
||||
Some devices failed
|
||||
.TP
|
||||
.B 11
|
||||
All devices failed
|
||||
.SH AUTHOR
|
||||
Written by Pim van Pelt.
|
||||
.SH REPORTING BUGS
|
@ -120,6 +120,14 @@ func main() {
|
||||
}
|
||||
|
||||
fmt.Printf("\nOverall summary: %d/%d devices processed successfully\n", successCount, totalCount)
|
||||
|
||||
// Set exit code based on results
|
||||
if successCount == 0 {
|
||||
os.Exit(11) // All devices failed
|
||||
} else if successCount < totalCount {
|
||||
os.Exit(10) // Some devices failed
|
||||
}
|
||||
// Exit code 0 (success) when all devices succeeded
|
||||
},
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user