Skip to content

Commit

Permalink
docs: add project site (#21)
Browse files Browse the repository at this point in the history
  • Loading branch information
bednar authored Jun 9, 2023
1 parent a49388f commit a709de2
Show file tree
Hide file tree
Showing 9 changed files with 129 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<a href="https://www.nuget.org/packages/InfluxDB3.Client">
<img src="https://buildstats.info/nuget/InfluxDB3.Client" alt="NuGet Badge">
</a>
<a href="https://influxcommunity.github.io/influxdb3-csharp/">
<img src="https://img.shields.io/badge/-docfx-blue?logo=csharp&logoColor=white" alt="docfx">
</a>
<a href="https://github.com/InfluxCommunity/influxdb3-csharp/actions/workflows/codeql-analysis.yml">
<img src="https://github.com/InfluxCommunity/influxdb3-csharp/actions/workflows/codeql-analysis.yml/badge.svg?branch=main" alt="CodeQL analysis">
</a>
Expand Down
9 changes: 9 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
###############
# folder #
###############
/**/DROP/
/**/TEMP/
/**/packages/
/**/bin/
/**/obj/
_site
5 changes: 5 additions & 0 deletions docs/api/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
###############
# temp file #
###############
*.yml
.manifest
69 changes: 69 additions & 0 deletions docs/docfx.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
{
"metadata": [
{
"src": [
{
"files": [
"**/Client/**.csproj"
],
"src": ".."
}
],
"dest": "api",
"disableGitFeatures": false,
"properties": {
"TargetFramework": "netstandard2.1"
}
}
],
"build": {
"content": [
{
"files": [
"api/**.yml",
"api/index.md"
]
},
{
"files": [
"toc.yml",
"*.md"
]
}
],
"resource": [
{
"files": [
"images/**",
"favicon.ico"
]
}
],
"overwrite": [
{
"files": [
],
"exclude": [
"obj/**",
"_site/**"
]
}
],
"dest": "_site",
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"statictoc"
],
"globalMetadata": {
"_appLogoPath": "images/influxdata-logo--symbol--white.png",
"_disableContribution": true
},
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
"keepFileLink": false,
"cleanupCacheHistory": false,
"disableGitFeatures": false
}
}
Binary file added docs/favicon.ico
Binary file not shown.
Binary file added docs/images/influxdata-logo--symbol--white.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# influxdb3-csharp

| Client | Description | API |
|----------|------------------------------------------------------------------------------------------|---------------------------------------------------|
| `Client` | The C# .NET client that provides an easy and convenient way to interact with InfluxDB 3. | [InfluxDB3.Client.html](api/InfluxDB3.Client.yml) |
35 changes: 35 additions & 0 deletions docs/publish-site.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/usr/bin/env bash

#
# Publish site to GitHub Pages
#
# How to run in Docker:
#
# docker run --rm -it \
# -v "${PWD}/docs":/code/docs \
# -v "${PWD}/.circleci":/code/.circleci \
# -v ~/.ssh:/root/.ssh \
# -v ~/.gitconfig:/root/.gitconfig \
# -w /code \
# bitnami/git:latest /code/docs/publish-site.sh
#

set -ev

echo "# Clone client and switch to branch for GH-Pages"
git clone -b gh-pages git@github.com:InfluxCommunity/influxdb3-csharp.git /code/influxdb3-csharp

echo "# Remove old pages"
rm -r /code/influxdb3-csharp/*

echo "# Copy new docs"
cp -Rf /code/docs/_site/* /code/influxdb3-csharp/

echo "# Copy CircleCI"
cp -R /code/.circleci/ /code/influxdb3-csharp/

echo "# Deploy site"
cd /code/influxdb3-csharp/ || exit
git add -f .
git -c commit.gpgsign=false commit -m "Pushed the latest Docs to GitHub pages [skip CI]"
git push -fq origin gh-pages
3 changes: 3 additions & 0 deletions docs/toc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- name: InfluxDB3.Client API
href: api/
homepage: api/InfluxDB3.Client.yml

0 comments on commit a709de2

Please sign in to comment.