| 1 | //! Workspace module - the defining unit of fackr |
| 2 | //! |
| 3 | //! A Workspace represents the editor state for a particular directory. |
| 4 | //! It is the container for all tabs, panes, cursors, and configuration. |
| 5 | //! |
| 6 | //! Directory structure: |
| 7 | //! ``` |
| 8 | //! <workspace_root>/ |
| 9 | //! .fackr/ |
| 10 | //! workspace.json # Persisted state (tabs, panes, cursors) |
| 11 | //! backups/ # Auto-backups of dirty files |
| 12 | //! ``` |
| 13 | //! |
| 14 | //! Workspace initialization: |
| 15 | //! - `fackr <dir>` - Opens directory as workspace |
| 16 | //! - `fackr <file>` - Implicitly opens containing directory as workspace |
| 17 | //! - `fackr` (no args) - Opens current directory as workspace |
| 18 | |
| 19 | mod recents; |
| 20 | mod state; |
| 21 | |
| 22 | pub use recents::{recents_add_or_update, recents_get, Recent}; |
| 23 | #[allow(unused_imports)] |
| 24 | pub use state::{BufferEntry, Pane, PaneBounds, PaneDirection, Tab, Workspace, WorkspaceConfig}; |
| 25 |