Update papis default template

This commit is contained in:
Yan Lin 2025-07-29 17:06:38 +02:00
parent e7cb1502e3
commit a45117a755
2 changed files with 28 additions and 13 deletions

View file

@ -434,29 +434,30 @@ papis add --from url https://example.com/paper.pdf
**Searching and browsing:**
```bash
# Search documents (uses fzf picker)
papis open
papis search "machine learning"
papis search author:smith year:2023
# List all documents
# List/search documents
papis list
papis list "machine learning"
papis list author:smith year:2023
# Open specific document
papis open smith2023
# Open documents (uses fzf picker)
papis open
papis open bohm
# Open document folder
papis open -d einstein
```
**Document management:**
```bash
# Edit document metadata
papis edit
papis edit bohm
# Export to BibTeX
papis export --all --format bibtex > references.bib
papis export search_term --format bibtex
papis export --format bibtex query_term > references.bib
# Show document information
papis show document_key
# List documents with custom format
papis list --format '{doc[author]} - {doc[title]} ({doc[year]})'
```
**Configuration location**: `modules/papis.nix` with embedded configuration

View file

@ -2,7 +2,7 @@
{
# Papis configuration
home.file.".config/papis/config".text = ''
home.file."Library/Application Support/papis/config".text = ''
[settings]
default-library = main
editor = nvim
@ -38,4 +38,18 @@
home.activation.createPapisDir = ''
mkdir -p ~/Documents/Library/papis
'';
# Papis bibliography template
home.file."Library/Application Support/papis/templates/bibitem.template".text = ''
{doc[title]} ({doc[year]}). {doc[author]}.
Venue: {doc[journal]} {doc[booktitle]} {doc[eprinttype]} {doc[eprint]} {doc[eventtitle]}
Tags: {doc[tags]}
URL: {doc[url]}
---
'';
# Shell alias for convenient bibliography formatting
programs.zsh.shellAliases = {
papis-bib = "papis list --template \"$HOME/Library/Application Support/papis/templates/bibitem.template\"";
};
}