Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
d4ad310
feat(golemcore/obsidian): scaffold obsidian plugin module
alexk-dev Mar 29, 2026
3c45d5f
fix(test): allow filtered reactor runs to skip upstream modules
alexk-dev Mar 29, 2026
8356722
fix(test): scope no-specified-tests handling to upstream modules
alexk-dev Mar 29, 2026
e79cf28
feat(golemcore/obsidian): add obsidian plugin settings
alexk-dev Mar 29, 2026
50e6035
fix(golemcore/obsidian): round-trip obsidian policy flags
alexk-dev Mar 29, 2026
aa98f3c
fix(golemcore/obsidian): tighten obsidian settings defaults
alexk-dev Mar 29, 2026
1a2fce1
feat(golemcore/obsidian): add obsidian api client
alexk-dev Mar 29, 2026
d4bc03f
fix(golemcore/obsidian): align obsidian api client contract
alexk-dev Mar 29, 2026
b68e7e6
fix(golemcore/obsidian): tighten obsidian api contract
alexk-dev Mar 29, 2026
2dcf72b
fix(golemcore/obsidian): fail fast on malformed obsidian payloads
alexk-dev Mar 29, 2026
5e62ca0
fix(golemcore/obsidian): reject blank note bodies
alexk-dev Mar 29, 2026
b049987
fix(golemcore/obsidian): allow optional search source
alexk-dev Mar 29, 2026
0a9c910
feat(golemcore/obsidian): add vault operation service
alexk-dev Mar 29, 2026
66fa085
fix(golemcore/obsidian): harden vault service semantics
alexk-dev Mar 29, 2026
8ff7322
fix(golemcore/obsidian): validate vault directory targets
alexk-dev Mar 29, 2026
d3312e9
feat(golemcore/obsidian): expose obsidian vault tool
alexk-dev Mar 29, 2026
97b2750
fix(golemcore/obsidian): tighten vault tool schema
alexk-dev Mar 29, 2026
de4e0be
fix(golemcore/obsidian): harden tool parameter handling
alexk-dev Mar 29, 2026
55a1b10
fix(golemcore/obsidian): add registry metadata and pass strict checks
alexk-dev Mar 29, 2026
752eaac
feat(golemcore/obsidian): add settings connection test
alexk-dev Mar 29, 2026
630c3af
chore(registry): sync obsidian artifact metadata
alexk-dev Mar 29, 2026
6746551
fix(registry): align obsidian checksum with CI build
alexk-dev Mar 29, 2026
d4bdd1a
chore(repo): remove plugin checksum enforcement
alexk-dev Mar 29, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 0 additions & 21 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,26 +36,6 @@ jobs:
- name: Build, test, and verify code quality
run: mvn -B -ntp -P strict verify

- name: Verify release-candidate registry checksums
if: github.event_name == 'pull_request'
shell: bash
run: |
mapfile -t plugins < <(python3 scripts/plugins_repo.py release-plan \
--rev-range "${{ github.event.pull_request.base.sha }}..${{ github.sha }}")
if (( ${#plugins[@]} == 0 )); then
echo "No release candidates changed in this PR."
exit 0
fi

for plugin_id in "${plugins[@]}"; do
python3 scripts/plugins_repo.py sync-local-registry --plugin "$plugin_id"
done

if ! git diff --exit-code -- registry; then
echo "::error::Registry metadata drift detected for release candidate plugins. Refresh the current registry version metadata from a fresh build before merging."
exit 1
fi

- name: Upload packaged artifacts
if: always()
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -181,7 +161,6 @@ jobs:

gh release create "${tag_name}" \
"${artifact_path}" \
"${artifact_sha256_path}" \
"${registry_version_path}" \
--title "${release_name}" \
--generate-notes
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/release-plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,5 +125,4 @@ jobs:
generate_release_notes: true
files: |
${{ steps.release.outputs.artifact_path }}
${{ steps.release.outputs.artifact_sha256_path }}
${{ steps.release.outputs.registry_version_path }}
16 changes: 3 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,21 +112,11 @@ Normal plugin releases are produced automatically after a merge to the default b
2. derives the SemVer bump from conventional commits since the last plugin tag
3. bumps the plugin version
4. packages the plugin from the repository state on the default branch
5. writes fresh `registry/` metadata, including checksum and published timestamp, from that built artifact
5. writes fresh `registry/` metadata, including artifact URL and published timestamp, from that built artifact
6. publishes the jar to GitHub Packages
7. commits release metadata, tags the release, and publishes the jar plus checksum file to GitHub Releases
7. commits release metadata, tags the release, and publishes the jar plus registry metadata to GitHub Releases

The manual GitHub Actions workflow `Release Plugin` exists for backfills or exceptional releases from the default branch. It follows the same packaging and checksum rules as the automatic release flow.

For local marketplace development after rebuilding plugin jars without a version bump, refresh registry metadata with:

- `python3 scripts/plugins_repo.py sync-local-registry`

Then verify the result with:

- `python3 scripts/plugins_repo.py validate --check-local-artifacts`

This local registry sync is only for local development or unreleased artifacts. Do not use it to rewrite the checksum of an already released version in a PR.
The manual GitHub Actions workflow `Release Plugin` exists for backfills or exceptional releases from the default branch. It follows the same packaging and publishing rules as the automatic release flow.

For normal releases use `bump=auto`. It derives `major` / `minor` / `patch` from conventional commits since the last plugin tag.

Expand Down
22 changes: 0 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,28 +90,6 @@ Use the helper script to validate manifests, module versions, and registry metad
python3 scripts/plugins_repo.py validate
```

If you want the script to also compare current registry checksums against locally built artifacts, run:

```bash
python3 scripts/plugins_repo.py validate --check-local-artifacts
```

### Local registry refresh for unreleased development builds

For local marketplace development only, refresh current registry metadata from locally built artifacts:

```bash
python3 scripts/plugins_repo.py sync-local-registry
```

You can also scope the refresh to one plugin:

```bash
python3 scripts/plugins_repo.py sync-local-registry --plugin golemcore/browser
```

Do not use local registry sync to rewrite metadata for an already released version in a PR.

## Release Model

Normal plugin releases are produced from the default branch.
Expand Down
7 changes: 7 additions & 0 deletions extension-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@
<groupId>net.revelc.code.formatter</groupId>
<artifactId>formatter-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<failIfNoSpecifiedTests>false</failIfNoSpecifiedTests>
</configuration>
</plugin>
</plugins>
</build>

Expand Down
12 changes: 12 additions & 0 deletions golemcore/obsidian/plugin.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
id: golemcore/obsidian
provider: golemcore
name: obsidian
version: 1.0.0
pluginApiVersion: 1
engineVersion: ">=0.0.0 <1.0.0"
entrypoint: me.golemcore.plugins.golemcore.obsidian.ObsidianPluginBootstrap
description: Obsidian vault plugin backed by obsidian-local-rest-api.
sourceUrl: https://github.com/alexk-dev/golemcore-plugins/tree/main/golemcore/obsidian
license: Apache-2.0
maintainers:
- alexk-dev
104 changes: 104 additions & 0 deletions golemcore/obsidian/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>me.golemcore.plugins</groupId>
<artifactId>golemcore-plugins</artifactId>
<version>1.0.0</version>
<relativePath>../../pom.xml</relativePath>
</parent>

<version>1.0.0</version>
<artifactId>golemcore-obsidian-plugin</artifactId>
<name>golemcore/obsidian</name>
<description>Obsidian vault plugin for GolemCore</description>

<properties>
<plugin.owner>golemcore</plugin.owner>
<plugin.name>obsidian</plugin.name>
<formatter.config.file>../../misc/formatter_eclipse.xml</formatter.config.file>
</properties>

<dependencies>
<dependency>
<groupId>me.golemcore.plugins</groupId>
<artifactId>golemcore-plugin-extension-api</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>me.golemcore.plugins</groupId>
<artifactId>golemcore-plugin-runtime-api</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp-jvm</artifactId>
<version>${okhttp.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<build>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
<resource>
<directory>${project.basedir}</directory>
<includes>
<include>plugin.yaml</include>
</includes>
<targetPath>META-INF/golemcore</targetPath>
</resource>
</resources>
<plugins>
<plugin>
<groupId>net.revelc.code.formatter</groupId>
<artifactId>formatter-maven-plugin</artifactId>
</plugin>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>copy-plugin-artifact</id>
<phase>package</phase>
<configuration>
<target>
<mkdir dir="${project.basedir}/../../dist/${plugin.owner}/${plugin.name}/${project.version}" />
<copy file="${project.build.directory}/${project.build.finalName}.jar"
tofile="${project.basedir}/../../dist/${plugin.owner}/${plugin.name}/${project.version}/${project.artifactId}-${project.version}.jar"
overwrite="true" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package me.golemcore.plugins.golemcore.obsidian;

import me.golemcore.plugin.api.extension.spi.PluginBootstrap;
import me.golemcore.plugin.api.extension.spi.PluginDescriptor;

public class ObsidianPluginBootstrap implements PluginBootstrap {

@Override
public PluginDescriptor descriptor() {
return PluginDescriptor.builder()
.id("golemcore/obsidian")
.provider("golemcore")
.name("obsidian")
.entrypoint(getClass().getName())
.build();
}

@Override
public Class<?> configurationClass() {
return ObsidianPluginConfiguration.class;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
package me.golemcore.plugins.golemcore.obsidian;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class ObsidianPluginConfig {

private static final String DEFAULT_BASE_URL = "http://127.0.0.1:27123";
private static final int DEFAULT_TIMEOUT_MS = 30_000;
private static final int DEFAULT_SEARCH_CONTEXT_LENGTH = 100;
private static final int DEFAULT_MAX_READ_CHARS = 12_000;

@Builder.Default
private Boolean enabled = false;

@Builder.Default
private String baseUrl = DEFAULT_BASE_URL;
private String apiKey;

@Builder.Default
private Integer timeoutMs = DEFAULT_TIMEOUT_MS;

@Builder.Default
private Boolean allowInsecureTls = false;

@Builder.Default
private Integer defaultSearchContextLength = DEFAULT_SEARCH_CONTEXT_LENGTH;

@Builder.Default
private Integer maxReadChars = DEFAULT_MAX_READ_CHARS;

@Builder.Default
private Boolean allowWrite = false;

@Builder.Default
private Boolean allowDelete = false;

@Builder.Default
private Boolean allowMove = false;

@Builder.Default
private Boolean allowRename = false;

public void normalize() {
if (enabled == null) {
enabled = false;
}
if (baseUrl == null || baseUrl.isBlank()) {
baseUrl = DEFAULT_BASE_URL;
} else {
baseUrl = trimTrailingSlash(baseUrl.trim());
}
if (timeoutMs == null || timeoutMs <= 0) {
timeoutMs = DEFAULT_TIMEOUT_MS;
}
if (allowInsecureTls == null) {
allowInsecureTls = false;
}
if (defaultSearchContextLength == null || defaultSearchContextLength <= 0) {
defaultSearchContextLength = DEFAULT_SEARCH_CONTEXT_LENGTH;
}
if (maxReadChars == null || maxReadChars <= 0) {
maxReadChars = DEFAULT_MAX_READ_CHARS;
}
if (allowWrite == null) {
allowWrite = false;
}
if (allowDelete == null) {
allowDelete = false;
}
if (allowMove == null) {
allowMove = false;
}
if (allowRename == null) {
allowRename = false;
}
}

private String trimTrailingSlash(String value) {
String trimmed = value;
while (trimmed.endsWith("/")) {
trimmed = trimmed.substring(0, trimmed.length() - 1);
}
return trimmed.isBlank() ? DEFAULT_BASE_URL : trimmed;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package me.golemcore.plugins.golemcore.obsidian;

import com.fasterxml.jackson.databind.ObjectMapper;
import lombok.RequiredArgsConstructor;
import me.golemcore.plugin.api.runtime.PluginConfigurationService;
import org.springframework.stereotype.Service;

import java.util.Map;

@Service
@RequiredArgsConstructor
public class ObsidianPluginConfigService {

static final String PLUGIN_ID = "golemcore/obsidian";

private final PluginConfigurationService pluginConfigurationService;
private final ObjectMapper objectMapper = new ObjectMapper();

public ObsidianPluginConfig getConfig() {
Map<String, Object> raw = pluginConfigurationService.getPluginConfig(PLUGIN_ID);
ObsidianPluginConfig config = raw.isEmpty()
? ObsidianPluginConfig.builder().build()
: objectMapper.convertValue(raw, ObsidianPluginConfig.class);
config.normalize();
return config;
}

@SuppressWarnings("unchecked")
public void save(ObsidianPluginConfig config) {
config.normalize();
pluginConfigurationService.savePluginConfig(PLUGIN_ID, objectMapper.convertValue(config, Map.class));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package me.golemcore.plugins.golemcore.obsidian;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

@Configuration(proxyBeanMethods = false)
@ComponentScan(basePackageClasses = ObsidianPluginConfiguration.class)
public class ObsidianPluginConfiguration {
}
Loading
Loading