Commit graph

11 commits

Author SHA1 Message Date
Ellie Huxtable
ca263834e9
Restructure account commands to account subcommand (#984)
* Stop running triggers on history delete

* Move to account management dir

* Alter trigger function to only run for inserts

* wip

* Add atuin account subcommands, and re-org delete

* Clarify docs

* Delete silly dupe migration

* Um where did this come from

* Oops, insert only plz
2023-05-17 21:28:37 +01:00
Ellie Huxtable
dcd77749dd
Add history deletion (#791)
* Drop events. I'd still like to do them, but differently

* Start adding delete api stuff

* Set mailmap

* Delete delete delete

* Fix tests

* Make clippy happy
2023-03-20 09:26:54 +00:00
Ellie Huxtable
e297b98f72
Add local event log storage (#390)
* Add event data structures

This adds the data structures required to start syncing events, rather
than syncing history directly.

Adjust event

Fix

Add event data structure to client

* Add server event table sql

* Add client event table migration

Adjust migration

* Insert into event table from client

* Add event merge function

Right now this just ensures we have the right amount of events given the
history we have

BUT it will also be used to merge CREATE/DELETE events, resulting in
history being deleted :)

* Make CI happy

* Adjust

* we don't limit history length any more

* Update atuin-client/src/database.rs

Co-authored-by: Conrad Ludgate <conradludgate@gmail.com>

* fix usage

* Fix typo

* New Rust, new clippy stuff

Co-authored-by: Conrad Ludgate <conradludgate@gmail.com>
2022-11-04 09:08:20 +00:00
Ellie Huxtable
23b9d34e16
Add configurable history length (#447)
* Add configurable history length

This allows servers to decide the max length of each history item they
want to store! Some users might have much larger history lines than
others.

This setting can be set to 0 to allow for unlimited history length. This
is not recommended for a public server install, but for a private one it
can work nicely.

* Format lol
2022-06-10 10:00:59 +01:00
Ellie Huxtable
796644e24e
Add created_at column to users (#354) 2022-04-26 22:27:51 +01:00
Ellie Huxtable
f8233bcb63
SQLx cannot run this migration OK (#353)
And also correct a typo
2022-04-26 18:17:56 +01:00
Ellie Huxtable
4030de4bea
Add btree index on history table (#345)
This speeds up a whole bunch of our queries by a *lot* :)
2022-04-26 09:32:59 +01:00
Ellie Huxtable
5aca6114d4
Allow for larger commands (#321)
Followup: Limit command length client side too
2022-04-21 18:54:58 +01:00
Ellie Huxtable
fe05d86bfa
Fix delete trigger (#317)
I've tested this again by deleting my full history and re-syncing, all
good.
2022-04-21 09:12:51 +01:00
Ellie Huxtable
b98a378861
Add count trigger (#308)
This can be used in a later PR to optimise our database usage
significantly. Avoiding COUNT will be fantastic for our CPU usage, and
therefore sync times.
2022-04-19 18:19:21 +01:00
Ellie Huxtable
156893d774
Update docs, unify on SQLx, bugfixes (#40)
* Begin moving to sqlx for local too

* Stupid scanners should just have a nice cup of tea

Random internet shit searching for /.env or whatever

* Remove diesel and rusqlite fully
2021-04-25 17:21:52 +00:00