Fix handling file names with periods before the file extension.
This commit is contained in:
parent
6ed35f4674
commit
d38b0a84f6
@ -88,7 +88,7 @@ ARG DOOMEMACS_PATH=/foreign_documents/doomemacs
|
||||
ARG DOOMEMACS_REPO=https://github.com/doomemacs/doomemacs.git
|
||||
RUN mkdir -p $DOOMEMACS_PATH && git -C $DOOMEMACS_PATH init --initial-branch=main && git -C $DOOMEMACS_PATH remote add origin $DOOMEMACS_REPO && git -C $DOOMEMACS_PATH fetch origin $DOOMEMACS_VERSION && git -C $DOOMEMACS_PATH checkout FETCH_HEAD
|
||||
|
||||
ARG WORG_VERSION=0c8d5679b536af450b61812246a3e02b8103f4b8
|
||||
ARG WORG_VERSION=ba6cda890f200d428a5d68e819eef15b5306055f
|
||||
ARG WORG_PATH=/foreign_documents/worg
|
||||
ARG WORG_REPO=https://git.sr.ht/~bzg/worg
|
||||
RUN mkdir -p $WORG_PATH && git -C $WORG_PATH init --initial-branch=main && git -C $WORG_PATH remote add origin $WORG_REPO && git -C $WORG_PATH fetch origin $WORG_VERSION && git -C $WORG_PATH checkout FETCH_HEAD
|
||||
|
5
org_mode_samples/document/category_multiple.org
Normal file
5
org_mode_samples/document/category_multiple.org
Normal file
@ -0,0 +1,5 @@
|
||||
#+CATEGORY: foo
|
||||
#+CATEGORY: bar
|
||||
#+begin_src text
|
||||
#+CATEGORY: baz
|
||||
#+end_src
|
@ -83,7 +83,7 @@ pub fn parse_file_with_settings<'g, 's, P: AsRef<Path>>(
|
||||
let full_path = file_path.as_ref().canonicalize()?;
|
||||
if doc.category.is_none() {
|
||||
let category = full_path
|
||||
.file_prefix()
|
||||
.file_stem()
|
||||
.expect("File should have a name.")
|
||||
.to_str()
|
||||
.expect("File name should be valid utf-8.");
|
||||
|
Loading…
Reference in New Issue
Block a user