journey-cli 0.9.9

A CLI-based journal application with automatic timestamping, vault management, and Obsidian integration
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
# Journey - A CLI-based Journal Application

Journey is a command-line journal application written in Rust that allows you to manage daily notes with automatic timestamping and flexible date/time handling.

## Features

- **Vault Management**: Create and manage multiple journal vaults
- **Obsidian Integration**: Import configuration from existing Obsidian vaults and plugins
- **Automatic Timestamping**: Notes are automatically timestamped
- **Flexible Date/Time**: Support for absolute dates, relative dates, and custom times
- **Category-Based Sections**: Organize notes into specific sections (work, personal, health, meetings)
- **Template Files**: Custom templates with variable substitution
- **Phrase Expansion**: Define shortcuts that expand to full phrases
- **Table & Bullet Formats**: Choose between bullet points or table format for notes
- **Cross-platform**: Works on Linux, macOS, and Windows
- **Dual Binary Architecture**: Separate `journey` and `journeyctl` commands

## Installation

### Using Cargo

```bash
cargo install journey-cli
```

### Build from Source

```bash
git clone https://github.com/ljantzen/journey.git
cd journey
cargo build --release
cargo install --path .
```

### Download Binaries

Download directly from the [GitHub releases page](https://github.com/ljantzen/journey/releases).

## Quick Start

### 1. Initialize a Vault

```bash
# Unix/Linux/macOS
journeyctl init --path ~/my-journal --name personal

# Windows
journeyctl init --path "%USERPROFILE%\my-journal" --name personal

# From existing Obsidian vault
journeyctl init --path ~/Documents/MyObsidianVault --obsidian
```

### 2. Add Notes

```bash
# Add a note for today
journey This is my first note

# Add a note for yesterday
journey --relative-date 1 Note for yesterday

# Add a note with specific time
journey --time 14:30 Afternoon meeting notes
```

### 3. List Notes

```bash
# List today's notes (default behavior)
journey

# List notes for specific date
journey --date 2025-10-24 --list

# List with table headers (if using table format)
journey --list --header
```

### 4. Organize with Categories

```bash
# Add notes to specific sections
journey -c work "Completed quarterly report"
journey -c personal "Had dinner with friends"
journey -c health "30 minutes of cardio"
```

## Binary Architecture

Journey uses two separate binaries:

### `journey` - Note Operations
Main journal application for daily note operations:
- Add notes
- List notes
- Edit notes

### `journeyctl` - Vault Management
Administrative tool for vault configuration:
- Initialize vaults
- Manage default vault
- List/unlist vaults
- Show today's file path

## Core Concepts

### Vaults
A vault is a directory containing your journal notes. You can have multiple vaults for different purposes (work, personal, projects, etc.).

### Notes & Timestamps
Each note is automatically timestamped when created. Notes are stored in daily markdown files with frontmatter.

### Categories
Organize notes within daily files using categories. Each category can have its own section header (e.g., "Work Notes", "Personal Notes").

## Basic Commands

### Adding Notes

```bash
# Basic note
journey My note content

# With date
journey --date 2025-10-24 Note for specific date

# Relative dates (positive = past, negative = future)
journey --relative-date 1 Note for yesterday
journey --relative-date -1 Note for tomorrow

# With time
journey --time 14:30 Note with specific time

# With category
journey -c work "Work-related note"

# From stdin (each line becomes a note)
echo -e "First note\nSecond note" | journey --stdin
```

### Listing Notes

```bash
# List today's notes
journey
journey --list

# List for specific date
journey --date 2025-10-24 --list

# List by category
journey --list -c work

# With table headers (table format only)
journey --list --header
```

### Editing Notes

```bash
# Edit today's notes
journey --edit

# Edit specific date
journey --date 2025-10-24 --edit
```

## Vault Management

### Initialize Vaults

```bash
# Regular vault
journeyctl init --path ~/journal --name personal

# From Obsidian vault (auto-detects plugins)
journeyctl init --path ~/Documents/ObsidianVault --obsidian
```

### Default Vault

```bash
# Set default vault
journeyctl set-default personal

# Show current default
journeyctl show-default

# Unset default
journeyctl unset-default
```

### List and Manage Vaults

```bash
# List all vaults
journeyctl list

# Unlist a vault (removes from config, doesn't delete files)
journeyctl unlist-vault vault-name

# Show today's file path
journeyctl today
journeyctl today --vault vault-name
journeyctl today --verbose
```

## Configuration

Configuration file location:
- **Linux**: `~/.config/journey/journey.yaml`
- **macOS**: `~/Library/Application Support/journey/journey.yaml`
- **Windows**: `%APPDATA%\journey\journey.yaml`

### Basic Configuration

```yaml
vaults:
  personal:
    name: personal
    path: ~/Documents/journal
    locale: en_US.UTF-8
    list_type: bullet  # or "table"
    section_header: "Daily Log"
    phrases: {}
```

### Advanced Configuration

```yaml
vaults:
  work:
    name: work
    path: ~/Documents/work-journal
    locale: en_US.UTF-8
    
    # File organization
    file_path_format: "{year}/{month:02}/{date:02}.md"
    template_file: ~/templates/work-daily.md
    
    # Note format
    list_type: table
    table_headers:
      time: "Time"
      content: "Content"
    
    # Category sections
    section_header: "General Notes"
    section_header_work: "Work Tasks"
    section_header_personal: "Personal Notes"
    section_header_health: "Health & Fitness"
    section_header_meetings: "Meeting Notes"
    
    # Phrase expansion
    phrases:
      "@meeting": "Team meeting about project status"
      "@standup": "Daily standup meeting"
      "@review": "Code review completed"
```

## Advanced Features

### Categories and Sections
Organize notes into different sections within your daily files. See [docs/CATEGORIES.md](docs/CATEGORIES.md) for details.

```bash
journey -c work "Completed deployment"
journey -c personal "Dinner with family"
```

### Template Files
Use custom templates for new daily files with variable substitution. See [docs/TEMPLATE_VARIABLES.md](docs/TEMPLATE_VARIABLES.md) for details.

```yaml
template_file: ~/templates/daily.md
```

### Phrase Expansion
Define shortcuts that expand to full phrases. See [docs/PHRASE_EXPANSION.md](docs/PHRASE_EXPANSION.md) for details.

```yaml
phrases:
  "@meeting": "Team meeting about project status"
```

### Custom File Paths
Organize notes in any directory structure. See [docs/FILE_PATH_FORMATS.md](docs/FILE_PATH_FORMATS.md) for details.

```yaml
file_path_format: "{year}/{month:02}/{date:02}.md"
```

### Table Mode
Display notes in table format with customizable headers. See [docs/TABLE_MODE.md](docs/TABLE_MODE.md) for details.

```yaml
list_type: table
```

### Obsidian Integration
Import configuration from Obsidian vaults and plugins. See [docs/OBSIDIAN_INTEGRATION.md](docs/OBSIDIAN_INTEGRATION.md) for details.

```bash
journeyctl init --path ~/ObsidianVault --obsidian
```

### Localization
Support for multiple locales with locale-aware date parsing and table headers. See [docs/LOCALIZATION.md](docs/LOCALIZATION.md) for details.

```yaml
locale: no_NO.UTF-8  # Norwegian
```

## Command Reference

### journey (Note Operations)

| Option | Description |
|--------|-------------|
| `<NOTE>` | Add a note (default action) |
| `-l, --list` | List notes for the specified date |
| `-e, --edit` | Edit notes for the specified date |
| `-d, --date <DATE>` | Specify date (multiple formats supported) |
| `-r, --relative-date <DAYS>` | Days offset (positive=past, negative=future) |
| `-t, --time <TIME>` | Specify time (HH:MM or HH:MM:SS) |
| `--time-format <FORMAT>` | Force time format (12h or 24h) |
| `-c, --category <CATEGORY>` | Specify category (work, personal, health, meetings) |
| `--header` | Include table headers when listing (table format only) |
| `--stdin` | Read input from stdin (each line = one note) |
| `-V, --vault <NAME>` | Specify vault name |
| `-v, --version` | Show version information |

### journeyctl (Vault Management)

| Command | Description |
|---------|-------------|
| `init --path <PATH>` | Initialize a new vault |
| `init --path <PATH> --obsidian` | Initialize from Obsidian vault |
| `list` | List all configured vaults |
| `set-default <NAME>` | Set default vault |
| `show-default` | Show current default vault |
| `unset-default` | Remove default vault |
| `unlist-vault <NAME>` | Remove vault from configuration |
| `today` | Show today's file path |
| `today --vault <NAME>` | Show path for specific vault |
| `today --verbose` | Show detailed information |

## Date Format Support

Journey supports multiple date formats based on your locale:

**English/US (`en_US.UTF-8`):**
- `2025-10-24` (ISO)
- `10/24/2025` (US)
- `October 24, 2025` (Long)

**Norwegian (`no_NO.UTF-8`):**
- `2025-10-24` (ISO)
- `24.10.2025` (Norwegian)
- `24. oktober 2025` (Long)

**Custom override:**
```yaml
date_format: "DD.MM.YYYY"
```

## Path Expansion

Journey supports automatic path expansion:

**Unix/Linux/macOS:**
```yaml
path: ~/Documents/journal  # Expands to /home/user/Documents/journal
```

**Windows:**
```yaml
path: "%USERPROFILE%\Documents\journal"  # Expands to C:\Users\user\Documents\journal
```

## File Structure

Default structure (can be customized):

```
vault-directory/
├── 2025-10-24.md
├── 2025-10-23.md
└── 2025-10-22.md
```

Each markdown file contains:

```markdown
---
date: 2025-10-24
---

- 13:35:27 This is my first note
- 13:35:35 This is my second note
```

Or in table format:

```markdown
---
date: 2025-10-24
---

| 13:35:27 | This is my first note |
| 13:35:35 | This is my second note |
```

## Examples

### Daily Workflow

```bash
# Morning: Add standup notes
journey -c work "@standup discussed project status"

# Afternoon: Log activities
journey -c work "Completed code review"
journey -c personal "Lunch with colleague"

# Evening: Review the day
journey --list
```

### Working with Multiple Vaults

```bash
# Set default vault
journeyctl set-default work

# Add to default vault
journey "Note in work vault"

# Add to specific vault
journey --vault personal "Note in personal vault"
```

### Batch Operations

```bash
# Import notes from file
cat notes.txt | journey --stdin

# Add multiple categorized notes
echo -e "Task 1\nTask 2\nTask 3" | journey --stdin -c work
```

### Integration with Other Tools

```bash
# Export today's notes
journey --list --header > daily-report.md

# Copy to clipboard (Linux)
journey --list --header | xclip -selection clipboard

# Email notes
journey --list --header | mail -s "Daily Notes" team@example.com

# Find today's file for external editing
vim $(journeyctl today)
```

## Documentation

Detailed documentation is available in the [docs/](docs/) directory:

- **[OBSIDIAN_INTEGRATION.md]docs/OBSIDIAN_INTEGRATION.md** - Obsidian vault integration
- **[CATEGORIES.md]docs/CATEGORIES.md** - Category-based section organization
- **[TEMPLATE_VARIABLES.md]docs/TEMPLATE_VARIABLES.md** - Template file variables
- **[PHRASE_EXPANSION.md]docs/PHRASE_EXPANSION.md** - Phrase shortcuts
- **[FILE_PATH_FORMATS.md]docs/FILE_PATH_FORMATS.md** - Custom file path formats
- **[TABLE_MODE.md]docs/TABLE_MODE.md** - Table format and headers
- **[LOCALIZATION.md]docs/LOCALIZATION.md** - Locale support and internationalization
- **[SECTION_BASED_NOTES.md]docs/SECTION_BASED_NOTES.md** - Section-based note organization
- **[DATE_FORMAT_OVERRIDE.md]docs/DATE_FORMAT_OVERRIDE.md** - Custom date formats
- **[TIME_FORMAT_OVERRIDE.md]docs/TIME_FORMAT_OVERRIDE.md** - Time format overrides
- **[DEFAULT_BEHAVIOR_UPDATE.md]docs/DEFAULT_BEHAVIOR_UPDATE.md** - Default behavior changes
- **[SINGLE_VAULT_AUTO_SELECTION.md]docs/SINGLE_VAULT_AUTO_SELECTION.md** - Single vault auto-selection

## Development

```bash
# Build
cargo build

# Run tests
cargo test

# Run with debug output
RUST_LOG=debug cargo run -- --help
```

## License

This software is licensed under a combined MIT and SPPL license. It is basically a MIT license, but in order to be compliant you need to send me a postcard. Details in [LICENSE](https://github.com/ljantzen/journey/blob/main/LICENSE).