Skip to content

Commit 6ceceda

Browse files
authored
Merge pull request #36 from philoserf/prepare-version-1.0.0
Plugin management transfer and version 1.0.0 release
2 parents 59eda0e + 59b8409 commit 6ceceda

24 files changed

+1079
-321
lines changed

.editorconfig

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
insert_final_newline = true
7+
indent_style = tab
8+
indent_size = 4
9+
tab_width = 4

.github/FUNDING.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
github: [philoserf]
2+
buy_me_a_coffee: philoserf

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
name: Bug report
3+
about: Report a bug
4+
title: ""
5+
labels: bug
6+
assignees: ""
7+
---
8+
9+
<!-- Before opening a bug report, consider the following steps:
10+
11+
- Disable any plugins or snippets that might be causing a conflict.
12+
- Update Obsidian to the latest version.
13+
- Restart Obsidian.
14+
15+
Now, let’s describe the bug:
16+
17+
- Provide a clear and concise description of the issue.
18+
19+
To reproduce the bug, follow these steps:
20+
21+
- Describe the actions you take to trigger the bug.
22+
23+
- Clearly state what you expect to happen.
24+
25+
If applicable, include screenshots to help illustrate your problem.
26+
27+
Finally, provide any relevant debug information. You can access this information in Obsidian by pressing Ctrl/Cmd-P, selecting “Show debug info,” and clicking “Copy to clipboard.” -->
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
name: Feature request
3+
about: Suggest a new feature
4+
title: ""
5+
labels: enhancement
6+
assignees: ""
7+
---
8+
9+
<!-- Is your feature request related to a specific problem? If so, please provide a clear and concise description of the issue. For instance, I often feel frustrated when […]
10+
11+
Next, describe the solution you envision for this problem. Clearly outline what you would like to achieve. -->

.github/dependabot.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "npm"
4+
directory: "/"
5+
schedule:
6+
interval: "weekly"

.github/workflows/codeql.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: "CodeQL"
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["main"]
8+
schedule:
9+
- cron: "16 15 * * 1"
10+
11+
jobs:
12+
analyze:
13+
name: Analyze (${{ matrix.language }})
14+
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
15+
permissions:
16+
security-events: write
17+
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
include:
22+
- language: javascript-typescript
23+
build-mode: none
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@v4
27+
28+
- name: Initialize CodeQL
29+
uses: github/codeql-action/init@v3
30+
with:
31+
languages: ${{ matrix.language }}
32+
build-mode: ${{ matrix.build-mode }}
33+
34+
- name: Perform CodeQL Analysis
35+
uses: github/codeql-action/analyze@v3
36+
with:
37+
category: "/language:${{matrix.language}}"

.github/workflows/release.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Release
2+
on:
3+
push:
4+
tags: ["*"]
5+
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v4
11+
- uses: actions/setup-node@v4
12+
with:
13+
node-version: "22"
14+
15+
- run: |
16+
npm install
17+
npm run build
18+
19+
- name: Package
20+
run: |
21+
mkdir dist
22+
cp main.js manifest.json README.md dist/
23+
zip -r release.zip dist/
24+
25+
- uses: actions/create-release@v1
26+
id: create_release
27+
env:
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
with:
30+
tag_name: ${{ github.ref }}
31+
release_name: ${{ github.ref }}
32+
33+
- uses: actions/upload-release-asset@v1
34+
env:
35+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
with:
37+
upload_url: ${{ steps.create_release.outputs.upload_url }}
38+
asset_path: ./release.zip
39+
asset_name: release-${{ github.ref_name }}.zip
40+
asset_content_type: application/zip

.gitignore

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
1-
# Intellij
2-
*.iml
3-
.idea
4-
5-
# npm
6-
node_modules
7-
package-lock.json
8-
9-
# build
101
main.js
11-
*.js.map
2+
node_modules/
3+
data.json
4+
.obsidian/appearance.json
5+
.obsidian/core-plugins.json
6+
.obsidian/graph.json
7+
.obsidian/workspace.json
8+
CHANGELOG.md

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.obsidian/

LICENSE

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
MIT License
2+
3+
Copyright 2025 by Mark Ayers
4+
Copyright 2020–2024 by Badr Bouslikhin
5+
6+
Permission is hereby granted, free of charge, to any person obtaining a copy
7+
of this software and associated documentation files (the "Software"), to deal
8+
in the Software without restriction, including without limitation the rights
9+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
copies of the Software, and to permit persons to whom the Software is
11+
furnished to do so, subject to the following conditions:
12+
13+
The above copyright notice and this permission notice shall be included in all
14+
copies or substantial portions of the Software.
15+
16+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22+
SOFTWARE.

README.md

Lines changed: 41 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,65 @@
11
# Obsidian Vault Changelog Plugin
22

3-
This is a simple plugin that maintains a changelog of recently edited files in your vault.
4-
The changelog update can be triggered both manually and automatically.
3+
A plugin to maintain a change log of recently edited files in your Obsidian vault. Updates can be triggered manually or automatically.
54

6-
<img src="https://raw.githubusercontent.com/MrZeroo00/obsidian-vault-changelog/main/resources/demo.png" width=50% height=50%>
5+
**Important:** The change log note will be entirely overwritten at each update. Use a dedicated change log note and embed it in other notes if needed.
76

8-
**Everything in the changelog note will be overwritten**. It's best to use a dedicated changelog note and embed it in other notes.
7+
**Note:** This is a continuation of the original work by Badr Bouslikhin from 2020 to 2024. In January, Badr entrusted the project to Mark Ayers by transferring the code repository. On behalf of the Obsidian community, I want to express our gratitude to Badr for this valuable contribution.
98

10-
<img src="https://raw.githubusercontent.com/MrZeroo00/obsidian-vault-changelog/main/resources/demo-embedded.png" width=50% height=50%>
9+
## Installation
1110

12-
## How to Install
11+
1. Open settings.
12+
2. Navigate to "Community plugins".
13+
3. Select "Browse".
14+
4. Search for "Changelog."
15+
5. Install and enable.
1316

14-
### Manual installation
17+
link: <https://obsidian.md/plugins?id=obsidian-vault-changelog#>
1518

16-
1. Download zip archive from GitHub releases page.
17-
1. Extract the archive into `<vault>/.obsidian/plugins`.
18-
1. Reload Obsidian
19+
## Usage
1920

20-
### From within Obsidian
21+
Use the command palette command `Vault Changelog: Update` to update the
22+
change log manually.
2123

22-
You can install the plugin via the Community Plugins tab within Obsidian. Just search for "Changelog".
24+
## Example
2325

24-
## How to use
25-
26-
Once the plugin is installed and activated, you must provide it with the changelog file path.
27-
28-
You can update the changelog using the new command `Vault changelog: update` in the command palette.
29-
30-
You can configure two other options:
31-
32-
1. Number of recent files to show in the changelog
33-
1. Automatic refresh of the changelog: this option automatically updates changelog on any note modification, deletion or rename.
34-
35-
### Changelog file location
36-
37-
The changelog file location input is the full absolute path (including .md extension).
38-
39-
```
40-
./
41-
├── notes/
42-
│ └── misc/
43-
│ └── changelog.md
44-
├── pictures/
45-
├── some-note.md
46-
└── some-other-note.md
26+
```markdown
27+
- 2024-01-28T1430 · [[Note Title]]
28+
- 2024-01-28T1425 · [[Another Note]]
4729
```
4830

49-
If you want to use `changelog.md` from the example above, you should input `notes/misc/changelog.md` in the preference pane.
31+
## Settings
5032

51-
## Development
33+
- **Auto Update**: Toggle automatic changelog updates (default: `false`)
34+
- **Changelog Path**: Location of changelog file (default: `Changelog.md`)
35+
- **Datetime Format**: Moment.js format string (default: `YYYY-MM-DD[T]HHmm`)
36+
- **Max Recent Files**: Number of files to track (default: `25`)
5237

53-
This project uses Typescript to provide type checking and documentation.
54-
This plugin depends on the latest [plugin API](https://github.com/obsidianmd/obsidian-api) in Typescript Definition format, which contains TSDoc comments describing what it does.
38+
## Changelog
5539

56-
**Note:** the Obsidian API is still in early alpha and is subject to change at any time!
40+
### v1.0.0
5741

58-
If you want to contribute to development and/or just customize it with your own
59-
tweaks, you can do the following:
42+
- placeholder
6043

61-
- Clone this repository.
62-
- `npm i` or `yarn` to install dependencies
63-
- `npm run build` to compile.
64-
- Copy `manifest.json`, `main.js` and `styles.css` to a subfolder of your plugins
65-
folder (e.g. `<vault>/.obsidian/plugins/obsidian-vault-changelog/`)
66-
- Reload obsidian to see changes
44+
### v0.1.0
6745

68-
## Notes
46+
- The initial release by Badr Bouslikhin
6947

70-
This is experimental and may have instability. It is possible that there are
71-
bugs which may delete data in the current note. Please make backups!
48+
## Code of conduct
7249

73-
## Common issues and solutions
50+
We are all human beings, being human. Treat each other with respect and decorum. Assume good intentions. Practice a "Yes, and" worldview.
7451

75-
### Issue 1: Couldn`t write changelog: check the file path
52+
## Contributing
7653

77-
1. Create a new file, for example - `notes/misc/changelog`
78-
2. Go to **Settings -> Plugin Option -> Vault Changelog**
79-
2. Enter path in **Changelog note location - notes/misc/changelog.md**
80-
3. Restart Obsidian
54+
- Open (or contribute to) a [Discussion on GitHub](https://github.com/philoserf/obsidian-vault-changelog/discussions)
55+
- Open (or contribute to) an [Issue on GitHub](https://github.com/philoserf/obsidian-vault-changelog/issues)
56+
- Open (or contribute to) a [Pull Request on GitHub](<(https://github.com/philoserf/obsidian-vault-changelog/pulls)>)
57+
- Discuss the plugin in the [Forum](https://forum.obsidian.md)
58+
- Discuss the plugin on [Discord](https://discord.gg/obsidianmd)
59+
60+
## Development
8161

82-
#### **Notes:**
83-
> - Make sure to keep a **_proper file path and a name_**, like the one I have used.
84-
> - If you are creating a new file with Obsidian, then **_don't put a (.md) extension_**.
62+
1. Clone this repository `gh repo clone philoserf/obsidian-vault-changelog`.
63+
2. Install dependencies with `npm install`.
64+
3. Build the project with `npm run build`.
65+
4. Add the `manifest.json` and `main.js` files to your plugins.

esbuild.config.mjs

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import esbuild from "esbuild";
2+
3+
const production = process.argv[2] === "production";
4+
5+
// Define the build options
6+
const buildOptions = {
7+
bundle: true,
8+
entryPoints: ["src/main.ts"],
9+
external: ["obsidian"],
10+
format: "cjs",
11+
minify: production,
12+
outfile: "main.js",
13+
target: "ESNext",
14+
};
15+
16+
// Build the plugin
17+
esbuild
18+
.build(buildOptions)
19+
.then(() => console.log("Build complete!"))
20+
.catch((err) => {
21+
console.error("Build failed:", err);
22+
process.exit(1);
23+
});

0 commit comments

Comments
 (0)