Skip to content

Commit 297239c

Browse files
authored
Merge pull request #4370 from chpatton013/main
Add Obsidian community gitignore files
2 parents d5ac09e + 930fa35 commit 297239c

File tree

3 files changed

+58
-0
lines changed

3 files changed

+58
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Excludes Obsidian workspace cache and plugins. All notes and core obsidian
2+
# configuration files are tracked by Git.
3+
4+
# The current application UI state (DOM layout, recently-opened files, etc.) is
5+
# stored in these files (separate for desktop and mobile) so you can resume
6+
# your session seamlessly after a restart. If you want to track UI state, use
7+
# the Workspaces core plugin instead of relying on these files.
8+
.obsidian/workspace.json
9+
.obsidian/workspace-mobile.json
10+
11+
# Obsidian plugins are stored under .obsidian/plugins/$plugin_name. They
12+
# contain metadata (manifest.json), application code (main.js), stylesheets
13+
# (styles.css), and user-configuration data (data.json).
14+
# We want to exclude all plugin-related files, so we can exclude everything
15+
# under this directory.
16+
.obsidian/plugins/**/*
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Excludes Obsidian workspace cache and plugin code, but retains plugin
2+
# configuration. All notes and user-controlled configuration files are tracked
3+
# by Git.
4+
#
5+
# !!! WARNING !!!
6+
#
7+
# Community plugins may store sensitive secrets in their data.json files. By
8+
# including these files, those secrets may be tracked in your Git repository.
9+
#
10+
# To ignore configurations for specific plugins, add a line like this after the
11+
# contents of this file (order is important):
12+
# .obsidian/plugins/{{plugin_name}}/data.json
13+
#
14+
# Alternatively, ensure that you are treating your entire Git repository as
15+
# sensitive data, since it may contain secrets, or may have contained them in
16+
# past commits. Understand your threat profile, and make the decision
17+
# appropriate for yourself. If in doubt, err on the side of not including
18+
# plugin configuration. Use one of the alternative gitignore files instead:
19+
# * NotesOnly.gitignore
20+
# * NotesAndCoreConfiguration.gitignore
21+
22+
# The current application UI state (DOM layout, recently-opened files, etc.) is
23+
# stored in these files (separate for desktop and mobile) so you can resume
24+
# your session seamlessly after a restart. If you want to track UI state, use
25+
# the Workspaces core plugin instead of relying on these files.
26+
.obsidian/workspace.json
27+
.obsidian/workspace-mobile.json
28+
29+
# Obsidian plugins are stored under .obsidian/plugins/$plugin_name. They
30+
# contain metadata (manifest.json), application code (main.js), stylesheets
31+
# (styles.css), and user-configuration data (data.json).
32+
# We only want to track data.json, so we:
33+
# 1. exclude everything under the plugins directory recursively,
34+
# 2. unignore the plugin directories themselves, which then allows us to
35+
# 3. unignore the data.json files
36+
.obsidian/plugins/**/*
37+
!.obsidian/plugins/*/
38+
!.obsidian/plugins/*/data.json
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Excludes all Obsidian-related configuration. All notes are tracked by Git.
2+
3+
# All Obsidian configuration and runtime state is stored here
4+
.obsidian/**/*

0 commit comments

Comments
 (0)