forked from acaprojects/couchbase-orm
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #90 from Mapotempo/add_docs
Add docs
- Loading branch information
Showing
21 changed files
with
2,490 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: documentation | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
docs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
- name: Install dependencies | ||
run: | | ||
pip install sphinx sphinx-book-theme | ||
- name: Sphinx build | ||
run: | | ||
cd docs/ | ||
make html | ||
- name: Deploy to Github Pages | ||
uses: peaceiris/actions-gh-pages@v4 | ||
with: | ||
public_branch: gh-pages | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: docs/_build/ | ||
force_orphan: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
_build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Minimal makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line, and also | ||
# from the environment for the first two. | ||
SPHINXOPTS ?= | ||
SPHINXBUILD ?= sphinx-build | ||
SOURCEDIR = . | ||
BUILDDIR = _build | ||
|
||
# Put it first so that "make" without argument is like "make help". | ||
help: | ||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
||
.PHONY: help Makefile | ||
|
||
# Catch-all target: route all unknown targets to Sphinx using the new | ||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
%: Makefile | ||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CouchbaseOrm Documentation | ||
================================= | ||
|
||
This subdirectory contains the high-level driver documentation, including | ||
tutorials and the reference. | ||
|
||
To build the documentation locally for review, install `sphinx` and | ||
`sphinx-book-theme`, then execute `make html` in this directory: | ||
|
||
pip install 'sphinx' sphinx-book-theme | ||
make html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Configuration file for the Sphinx documentation builder. | ||
# | ||
# This file only contains a selection of the most common options. For a full | ||
# list see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Path setup -------------------------------------------------------------- | ||
|
||
# If extensions (or modules to document with autodoc) are in another directory, | ||
# add these directories to sys.path here. If the directory is relative to the | ||
# documentation root, use os.path.abspath to make it absolute, like shown here. | ||
# | ||
# import os | ||
# import sys | ||
# sys.path.insert(0, os.path.abspath('.')) | ||
|
||
|
||
# -- Project information ----------------------------------------------------- | ||
|
||
project = 'CouchbaseOrm' | ||
copyright = '2024, Woop' | ||
|
||
|
||
# -- General configuration --------------------------------------------------- | ||
|
||
# Add any Sphinx extension module names here, as strings. They can be | ||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom | ||
# ones. | ||
extensions = [ | ||
] | ||
|
||
# Add any paths that contain templates here, relative to this directory. | ||
templates_path = ['_templates'] | ||
|
||
# List of patterns, relative to source directory, that match files and | ||
# directories to ignore when looking for source files. | ||
# This pattern also affects html_static_path and html_extra_path. | ||
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] | ||
|
||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
|
||
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
html_theme = 'alabaster' | ||
|
||
# Add any paths that contain custom static files (such as style sheets) here, | ||
# relative to this directory. They are copied after the builtin static files, | ||
# so a file named "default.css" will overwrite the builtin "default.css". | ||
html_static_path = ['_static'] | ||
|
||
source_suffix = { | ||
'.txt': 'restructuredtext', | ||
} | ||
|
||
html_theme = 'sphinx_book_theme' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.. |x| unicode:: U+2717 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.. |checkmark| unicode:: U+2713 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
.. _couchbaseorm: | ||
|
||
************ | ||
CouchbaseOrm | ||
************ | ||
|
||
.. default-domain:: woop | ||
|
||
CouchbaseOrm is the non-official supported object-document record (ORM) for Couchbase in | ||
Ruby. | ||
|
||
.. toctree:: | ||
:titlesonly: | ||
|
||
installation-configuration | ||
schema-configuration | ||
working-with-data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
.. _installation-configuration: | ||
|
||
**************************** | ||
Installation & Configuration | ||
**************************** | ||
|
||
.. default-domain:: woop | ||
|
||
.. toctree:: | ||
:titlesonly: | ||
|
||
installations | ||
reference/compatibility | ||
reference/configuration | ||
reference/rails-integration | ||
|
||
Overview | ||
-------- | ||
|
||
Learn how to install and configure CouchbaseOrm in the following sections: | ||
|
||
- :ref:`Installation <installation>` | ||
- :ref:`Compatibility <compatibility>` | ||
- :ref:`Configuration <configuration>` | ||
- :ref:`Rails Integration <rails-integration>` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
.. _installation: | ||
|
||
************ | ||
Installation | ||
************ | ||
|
||
.. default-domain:: woop | ||
|
||
.. contents:: On this page | ||
:local: | ||
:backlinks: none | ||
:depth: 2 | ||
:class: singlecol | ||
|
||
Install the Gem | ||
=============== | ||
|
||
CouchbaseOrm is hosted on github https://github.com/Mapotempo/couchbase-orm. | ||
It can be installed manually or with bundler. | ||
|
||
To install the gem with bundler, include the following in your ``Gemfile``: | ||
|
||
.. code-block:: ruby | ||
|
||
git_source(:github) do |repo_name| | ||
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?('/') | ||
"https://github.com/#{repo_name}.git" | ||
end | ||
|
||
gem 'couchbase-orm', github: 'Mapotempo/couchbase-orm' | ||
gem 'couchbase', '~> 3.3.0' |
Oops, something went wrong.