Skip to content

Commit 66e0741

Browse files
authored
Merge pull request #4951 from marcduiker/remove-go-sdk-submodule
Move Go SDK docs & pluggable component docs into main Docs & remove go sdk submodule
2 parents 7b2a00b + 260fd27 commit 66e0741

File tree

16 files changed

+1747
-11
lines changed

16 files changed

+1747
-11
lines changed

.gitmodules

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,6 @@
55
path = translations/docs-zh
66
url = https://github.com/dapr/docs-zh.git
77
branch = v1.0_content
8-
[submodule "sdkdocs/go"]
9-
path = sdkdocs/go
10-
url = https://github.com/dapr/go-sdk.git
11-
[submodule "sdkdocs/pluggable-components/go"]
12-
path = sdkdocs/pluggable-components/go
13-
url = https://github.com/dapr-sandbox/components-go-sdk
148
[submodule "sdkdocs/rust"]
159
path = sdkdocs/rust
1610
url = https://github.com/dapr/rust-sdk.git

hugo.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -290,10 +290,10 @@ module:
290290
- source: sdkdocs/dotnet/content/en/dotnet-sdk-contributing
291291
target: content/contributing/sdk-contrib/
292292
lang: en
293-
- source: sdkdocs/go/daprdocs/content/en/go-sdk-docs
293+
- source: sdkdocs/go/content/en/go-sdk-docs
294294
target: content/developing-applications/sdks/go
295295
lang: en
296-
- source: sdkdocs/go/daprdocs/content/en/go-sdk-contributing
296+
- source: sdkdocs/go/content/en/go-sdk-contributing
297297
target: content/contributing/sdk-contrib/
298298
lang: en
299299
- source: sdkdocs/java/content/en/java-sdk-docs
@@ -317,7 +317,7 @@ module:
317317
- source: sdkdocs/pluggable-components/dotnet/content/en/dotnet-sdk-docs
318318
target: content/developing-applications/develop-components/pluggable-components/pluggable-components-sdks/pluggable-components-dotnet
319319
lang: en
320-
- source: sdkdocs/pluggable-components/go/daprdocs/content/en/go-sdk-docs
320+
- source: sdkdocs/pluggable-components/go/content/en/go-sdk-docs
321321
target: content/developing-applications/develop-components/pluggable-components/pluggable-components-sdks/pluggable-components-go
322322
lang: en
323323
- source: translations/docs-zh/translated_content/zh_CN/docs

sdkdocs/go

Lines changed: 0 additions & 1 deletion
This file was deleted.

sdkdocs/go/README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Dapr Go SDK documentation
2+
3+
This page covers how the documentation is structured for the Dapr Go SDK
4+
5+
## Dapr Docs
6+
7+
All Dapr documentation is hosted at [docs.dapr.io](https://docs.dapr.io), including the docs for the [Go SDK](https://docs.dapr.io/developing-applications/sdks/go/). Head over there if you want to read the docs.
8+
9+
### Go SDK docs source
10+
11+
Although the docs site code and content is in the [docs repo](https://github.com/dapr/docs), the Go SDK content and images are within the `content` and `static` directories, respectively.
12+
13+
This allows separation of roles and expertise between maintainers, and makes it easy to find the docs files you are looking for.
14+
15+
## Writing Go SDK docs
16+
17+
To get up and running to write Go SDK docs, visit the [docs repo](https://github.com/dapr/docs) to initialize your environment. It will clone both the docs repo and this repo, so you can make changes and see it rendered within the site instantly, as well as commit and PR into this repo.
18+
19+
Make sure to read the [docs contributing guide](https://docs.dapr.io/contributing/contributing-docs/) for information on style/semantics/etc.
20+
21+
## Docs architecture
22+
23+
The docs site is built on [Hugo](https://gohugo.io), which lives in the docs repo. This repo is setup as a git submodule so that when the repo is cloned and initialized, the dotnet-sdk repo, along with the docs, are cloned as well.
24+
25+
Then, in the Hugo configuration file, the `daprdocs/content` and `daprdocs/static` directories are redirected to the `daprdocs/developing-applications/sdks/go` and `static/go` directories, respectively. Thus, all the content within this repo is folded into the main docs site.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
type: docs
3+
title: "Contributing to the Go SDK"
4+
linkTitle: "Go SDK"
5+
weight: 3000
6+
description: Guidelines for contributing to the Dapr Go SDK
7+
---
8+
9+
When contributing to the [Go SDK](https://github.com/dapr/go-sdk) the following rules and best-practices should be followed.
10+
11+
## Examples
12+
13+
The `examples` directory contains code samples for users to run to try out specific functionality of the various Go SDK packages and extensions. When writing new and updated samples keep in mind:
14+
15+
- All examples should be runnable on Windows, Linux, and MacOS. While Go code is consistent among operating systems, any pre/post example commands should provide options through [tabpane]({{% ref "contributing-docs.md#tabbed-content" %}})
16+
- Contain steps to download/install any required pre-requisites. Someone coming in with a fresh OS install should be able to start on the example and complete it without an error. Links to external download pages are fine.
17+
18+
## Docs
19+
20+
The `daprdocs` directory contains the markdown files that are rendered into the [Dapr Docs](https://docs.dapr.io) website. When the documentation website is built this repo is cloned and configured so that its contents are rendered with the docs content. When writing docs keep in mind:
21+
22+
- All rules in the [docs guide]({{% ref contributing-docs.md %}}) should be followed in addition to these.
23+
- All files and directories should be prefixed with `go-` to ensure all file/directory names are globally unique across all Dapr documentation.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
type: docs
3+
title: "Dapr Go SDK"
4+
linkTitle: "Go"
5+
weight: 1000
6+
description: Go SDK packages for developing Dapr applications
7+
no_list: true
8+
cascade:
9+
github_repo: https://github.com/dapr/go-sdk
10+
github_subdir: daprdocs/content/en/go-sdk-docs
11+
path_base_for_github_subdir: content/en/developing-applications/sdks/go/
12+
github_branch: main
13+
---
14+
15+
A client library to help build Dapr applications in Go. This client supports all public Dapr APIs while focusing on idiomatic Go experiences and developer productivity.
16+
17+
{{% cardpane %}}
18+
{{% card title="**Client**"%}}
19+
Use the Go Client SDK for invoking public Dapr APIs
20+
21+
[Learn more about the Go Client SDK]({{% ref go-client %}})
22+
{{% /card %}}
23+
{{% card title="**Service**"%}}
24+
Use the Dapr Service (Callback) SDK for Go to create services that will be invoked by Dapr.
25+
26+
[Learn more about the Go Service (Callback) SDK]({{% ref go-service %}})
27+
{{% /card %}}
28+
{{% /cardpane %}}

0 commit comments

Comments
 (0)