Commit Graph

136 Commits

Author SHA1 Message Date
creme 25dbb94f7e
Merge remote-tracking branch 'upstream/master' 2021-10-24 11:17:51 +02:00
Benjamin Morrison 116734fc4b
let's actually set the file permissions this time 2021-10-24 02:24:48 -04:00
Benjamin Morrison 5d46c86e08
fix moved val compile error 2021-10-24 02:20:45 -04:00
Benjamin Morrison 91b0ee7aff
set ~/.clinte.json to 644 2021-10-24 02:14:45 -04:00
creme 62daefee15
Merge remote-tracking branch 'upstream/master' 2020-07-10 18:11:52 +02:00
Benjamin Morrison 06af54fd60
removed panic on error in favor of exit(1) and clean msg 2020-07-06 01:12:30 -04:00
creme c60854a4c0
Merge remote-tracking branch 'upstream/master' 2020-07-04 23:05:03 +02:00
Benjamin Morrison f682df279f
version bump to 2.1.4 2020-07-03 19:54:19 -04:00
Benjamin Morrison 4b30a05ba2
explicit test if /etc/profile.d is a directory rather than for the
general existence of /etc/profile.d
2020-07-03 19:49:33 -04:00
Benjamin Morrison 3eac3167ac
switching from a full build to 'cargo check' in CI
accomplishes mostly the same thing for my purposes and reduces
the CI run time.
2020-07-03 19:40:48 -04:00
Benjamin Morrison a69f61ca98
moved makefile install target to shellscript
Testing for OS before decided what group to assign to binary and
files. If Linux, both groups are 'root'. If OpenBSD, the groups
are 'bin' and 'wheel'. I don't have a FreeBSD or NetBSD system
handy right now to check those.
2020-07-03 19:14:51 -04:00
Benjamin Morrison e7544b9b1d
corrected post subject stated max length in man page 2020-07-03 18:15:45 -04:00
Benjamin Morrison fe77fcfc55
man page for clinte
Amended Makefile to install said man page.
Explicitly installing files -o root -g root.
2020-07-03 17:02:24 -04:00
Benjamin Morrison 9d8bbab3ce
allow per-user suppression of clinte notifications
If a user places a file at $HOME/.hushclinte, they will not be
notified of new posts on login.

Moved check logic to a function. Test if .hushclinte exists. If
it doesn't, run the announce function (check_clinte).

Also fixed a shellcheck error - unquoted variable expansion.
Changed string literals to single-quotes.
2020-07-02 19:02:45 -04:00
creme 5476c655db
Merge remote-tracking branch 'upstream/master' 2020-07-02 08:24:07 +02:00
Ben Morrison e63da0b7e0
check if $EDITOR contains flags before calling
If it contains flags, split by whitespace and pass them in as arguments
to std::process::Command. Otherwise, just pass it in as normal. This was
causing a panic/abort.
2020-07-02 02:11:03 -04:00
creme 69110478e9
Merge remote-tracking branch 'upstream/master' 2020-06-17 18:33:42 +02:00
Ben Morrison e5c197812e
crate version bump 2020-06-17 02:08:53 -04:00
Ben Morrison 95b0bbd7cc
added removal of notify script to uninstall target 2020-06-17 02:07:07 -04:00
Ben Morrison a0d9d84d42
testing for OS to improve portability of new post notification 2020-06-17 02:03:10 -04:00
Ben Morrison 39ca959bfa
updated repo location to sr.ht 2020-06-16 23:44:10 -04:00
Ben Morrison fef5f9ffa8
added sr.ht info to readme
re: sending patches, and build status
2020-06-16 23:38:48 -04:00
Ben Morrison 3954b2ad04
added extra newline after new message notification 2020-06-16 23:26:01 -04:00
Ben Morrison e7926ccff6
crate version bump 2020-06-16 20:33:16 -04:00
Ben Morrison 15006ab61d
redirecting stderr to /dev/null
stops an error if a user has never used clinte
2020-06-16 20:30:31 -04:00
Ben Morrison 1e51bf9ab5
removed outdated wording about make behavior 2020-06-16 20:20:50 -04:00
Ben Morrison 5b3f2a60bf
crate version bump 2020-06-16 20:18:01 -04:00
Ben Morrison 0fe685c34c
moved hashing to shellscript to check for posts
removes dependency on sha2 crate and allows users
to choose their own hashing algorithm easily.

now copies clinte.json to $HOME/.clinte.json once
the posts are viewed. a shellscript can be used to
compare the hash of the global clinte.json to the
hash of the copy. an example script is supplied.

on `make install` the example script is installed
to /etc/profile.d/, where it will be run for users
on login.
2020-06-16 20:14:37 -04:00
Ben Morrison 40bb48bb70
test for hashing bits 2020-06-16 19:16:49 -04:00
Ben Morrison c4c9412c3f
recording hash of posts file in homedir
sha256.
This will facilitate checking for new posts on login.
2020-06-16 19:00:08 -04:00
Ben Morrison d033f0d239
including manifest for sourcehut builds 2020-06-16 15:31:08 -04:00
Ben Morrison e3e3047da7
removed old packages from travis 2020-06-16 15:14:15 -04:00
Ben Morrison 69ad4de4ca
changed upgrade steps
changed refs to v2.0.0 -> v2.x
2020-06-16 15:08:11 -04:00
Ben Morrison ad215ba851
install target: check for clinte.json before copying
removed upgrade target since it's now redundant
2020-06-16 15:03:51 -04:00
Ben Morrison 0c32375287
moved startup timer to end of execution, as run timer 2020-06-15 17:51:43 -04:00
Ben Morrison fdab1b0117
updated usage for linewrap 2020-06-09 03:06:02 -04:00
Ben Morrison 9b749b9464
configurable line wrapping (80 default)
disabled when set to a value below 10
2020-06-09 03:00:38 -04:00
Ben Morrison 1e6f1de062
removed tag checkout when building 2020-06-09 03:00:23 -04:00
creme db16397c63
Merge remote-tracking branch 'upstream/master' 2020-05-29 09:53:08 +02:00
Ben Morrison 8d0f0b4e0d
clarified upgrade process and note section 2020-05-28 18:32:07 -04:00
Ben Morrison 2cb85a4f59
testing create/delete 2020-05-28 18:18:32 -04:00
Ben Morrison ec59c5f5d8
make test is now single-threaded 2020-05-28 13:01:45 -04:00
Ben Morrison 967ac7e1f4
travis using single-threaded testing 2020-05-28 13:00:40 -04:00
Ben Morrison 87bf08a5cf
expanded testing 2020-05-28 12:51:07 -04:00
Ben Morrison 3578c80391
bumped version in Cargo.toml 2020-05-28 12:32:18 -04:00
Ben Morrison e4856f6ba8
more testing 2020-05-28 03:31:43 -04:00
Ben Morrison bb327d381e
extensive rewrite to use json for storage:
sqlite3 requires the directory where the database resides to be
writeable by the user. This presents a problem on multiuser UNIX systems
where they may want to limit areas where users have write access.

This rewrite totally scraps the sqlite3 database in favor of a pretty
simple json file consisting of an array of posts. flock(2) locking is
used to synchronize access to the file and make sure two clients aren't
trying to write to it at once. The locking is fairly granular right now,
but later I may change it to using a single lock for the duration of
execution since race conditions are *possible*, if unlikely for the
purposes of clinte's intended use.
2020-05-28 02:58:57 -04:00
creme 7aee0a55ce
Merge remote-tracking branch 'upstream/master' 2020-05-27 20:50:43 +02:00
Ben Morrison e4af0011c0
updated readme 2020-05-27 12:05:41 -04:00
creme 35a1d1032d
.drone.yml: fix env path usage 2020-05-27 08:47:49 +02:00