kevins8
08/31/2020, 6:45 PMkevins8
08/31/2020, 6:46 PMdendron/packages/engine-server/node_modules/vscode-uri/lib/esm/index.d.ts
kevins8
08/31/2020, 6:47 PMvscode-uri
is listed as a dependency
in engine-server
. is it showing up under node_modules
in engine-server
?jojanaho
08/31/2020, 6:51 PMimport { URI } from "vscode-URI";
to import { URI } from "vscode-uri";
jojanaho
08/31/2020, 6:51 PMvscode-uri
kevins8
08/31/2020, 6:53 PMvscode-URI
was probably from me fat fingering a ~
while in `vim`π
might be something to do with case sensitive file systems that results in an error when you're building? whatever the case, it should probably be lowercase moving forward πjojanaho
08/31/2020, 6:54 PMkevins8
08/31/2020, 6:54 PMjojanaho
08/31/2020, 6:55 PMkevins8
08/31/2020, 6:55 PMkevins8
08/31/2020, 6:56 PMFile System Personality: APFS
Type (Bundle): apfs
Name (User Visible): APFS
Owners: Enabled
kevins8
08/31/2020, 6:56 PMkevins8
08/31/2020, 6:56 PMjojanaho
08/31/2020, 6:56 PMkevins8
08/31/2020, 6:59 PMjojanaho
08/31/2020, 7:54 PMtypescript
const cNoteFname =
opts?.overrides?.domain || path.basename(editorPath, ".md");
jojanaho
08/31/2020, 7:54 PMdendron.demo.md
vs pro.foo.md
). If changing that to be the same, the second and third became equal:
childOfDomain:
dendron.demo.md -> create new journal note -> dendron.journal.2020-08-03.md
childOfDomainNamespace:
dendron.demo.md -> create new journal note -> dendron.demo.journal.2020-08-03.md
childOfCurrent:
dendron.demo.md -> create new journal note -> dendron.demo.journal.2020-08-03.md
asOwnDomain:
dendron.demo.md -> create new journal note -> journal.2020-08-03.md
jojanaho
08/31/2020, 7:56 PMsibling:
tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.notes.journal.2020-08-03.md
child:
tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.notes.demo.journal.2020-08-03.md
root:
tools.dendron.remarks.md -> create new journal note -> journal.2020-08-03.md
schema:
tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.journal.2020-08-03.md
in this example, the schema-option assumes that "tools" is defined in the schema, and it has set namespace to true.
Continuing on this, the term "namespace" is also somewhat hard to understand correctly. Elsewhere in the docs: "when a schema is a namespace, it can have arbitrary children. equivalent to cli.* glob pattern". What makes this difficult is that any node in the schema can anyway have arbitrary children, since "...you can create notes that donβt match any schema". Anyway, after spending some time on this, I think I now know how it works. Maybe formulating namespace something like this could help "making a schema node a namespace automatically brings its immediate children as part of the schema, even if they are not explicitly defined in the schema definition".kevins8
08/31/2020, 9:23 PMtypescript
> const cNoteFname =
> opts?.overrides?.domain || path.basename(editorPath, ".md");
>
@User you're right. all note creation requires a current active editor unless _noteAddBehaviorEnum = 'asOwnDomain'
kevins8
08/31/2020, 9:23 PMdendron.demo.md
vs pro.foo.md
). If changing that to be the same, the second and third became equal:
>
> > childOfDomain:
> dendron.demo.md -> create new journal note -> dendron.journal.2020-08-03.md
>
> childOfDomainNamespace:
> dendron.demo.md -> create new journal note -> dendron.demo.journal.2020-08-03.md
>
> childOfCurrent:
> dendron.demo.md -> create new journal note -> dendron.demo.journal.2020-08-03.md
>
> asOwnDomain:
> dendron.demo.md -> create new journal note -> journal.2020-08-03.md
>
@User
and that's a fair point. i updated the second example so that the first and second wouldn't look the same but i will update them all to use the same hierarchy to drive home the pointkevins8
08/31/2020, 9:26 PM> sibling:
> tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.notes.journal.2020-08-03.md
>
> child:
> tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.notes.demo.journal.2020-08-03.md
>
> root:
> tools.dendron.remarks.md -> create new journal note -> journal.2020-08-03.md
>
> schema:
> tools.dendron.notes.demo.md -> create new journal note -> tools.dendron.journal.2020-08-03.md
>
> in this example, the schema-option assumes that "tools" is defined in the schema, and it has set namespace to true.
>
>
> Continuing on this, the term "namespace" is also somewhat hard to understand correctly. Elsewhere in the docs: "when a schema is a namespace, it can have arbitrary children. equivalent to cli.* glob pattern". What makes this difficult is that any node in the schema can anyway have arbitrary children, since "...you can create notes that donβt match any schema". Anyway, after spending some time on this, I think I now know how it works. Maybe formulating namespace something like this could help "making a schema node a namespace automatically brings its immediate children as part of the schema, even if they are not explicitly defined in the schema definition".
@User
i use domain
to mean the root of the current hierarchy. i like your simplified values, would just swap root
with domain
. in the future, instead of having parent: root
in the default schema to indicate that it is the root of the hierarchy, planning on adding a domain: true
property instead and removing parent
altogetherkevins8
08/31/2020, 9:28 PMaddBehavior
values. we have a way of automatically upgrading old settings here: https://github.com/dendronhq/dendron/blob/master/packages/plugin-core/src/commands/UpgradeSettings.ts#L1:L1
its currently only used to set new defaults but can also be used to change existing values.kevins8
08/31/2020, 9:30 PMkevins8
09/01/2020, 4:50 AMjojanaho
09/01/2020, 3:41 PMschema
would be exactly that, and root
would be the absolute root of the whole vault. IIUC, domain is the immediate child of the absolute root? I'm somewhat confused with the terminology...
I think there's at least the following concepts:
1. root: the absolute root of the vault
2. static schema node: things defined explicitly in the schema
3. dynamic schema node: node that belongs to the schema via namespace mechanism
4. non-schema node: node which doesn't appear in schema or isn't an immediate child of a namespace schema node
5. domain: an immediate child of the root (?). Might be 2 or 4?kevins8
09/01/2020, 3:52 PMschemas
and notes
, and that the two relate to each other but are also independent.
### schemas
- namespace: a schema can be designated as a namespace. if so, it will match all its children and designate them as a match
### notes
.
βββ root.md --> absolute root of vault
βββ project.md --> root of project hierarchy. also referred to as the hierarchy **domain**
βββ project.foo.md --> a note within the project hierarchy
### add behavior
- for all below examples, assume that pro.dendron.demo.md
is opened and that pro
matches a namespace schema
- childOfDomain: add new note as child of the current domain (aka root of current hierarchy). doesn't take into account schema
- output: pro.journal
- childOfDomainNamespace: add new note as child of the current domain. if domain matches a namespace schema, make it into a child of that instead
- output: pro.dendron.journal
- childOfCurrent: add new note as child of whatever note your currently on
- output: pro.dendron.demo.journal
- asOwnDomain: add new note as its own domain. dis-regards current open note
- output: journal
(domain name specified by default{NodeType}Name
)jojanaho
09/01/2020, 4:10 PMjojanaho
09/01/2020, 4:11 PMjojanaho
09/01/2020, 4:12 PMkevins8
09/01/2020, 4:12 PMchildOfDomainNamespace