Skip to content

Commit

Permalink
feat(console): Added check to allow publishing of a component without…
Browse files Browse the repository at this point in the history
… docs
  • Loading branch information
espressif-abhikroy committed Oct 12, 2023
1 parent 1ac4e41 commit 19dafb8
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 15 deletions.
30 changes: 17 additions & 13 deletions .github/workflows/publish-docs-component.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,15 @@ jobs:
sudo apt-get -y install doxygen clang python3-pip
python -m pip install breathe recommonmark esp-docs==1.4.1
for comp in `ls components`; do
cd $GITHUB_WORKSPACE/docs/${comp}
if [[ "${{ env.BUMP_COMPONENT }}" == "${comp}" ]]; then
echo "Building specific version of ${comp} (${{ env.BUMP_VERSION }})"
./generate_docs ${{ env.BUMP_VERSION }}
else
echo "Building latest version of ${comp}"
./generate_docs
if [ -d $GITHUB_WORKSPACE/docs/${comp} ]; then
cd $GITHUB_WORKSPACE/docs/${comp}
if [[ "${{ env.BUMP_COMPONENT }}" == "${comp}" ]]; then
echo "Building specific version of ${comp} (${{ env.BUMP_VERSION }})"
./generate_docs ${{ env.BUMP_VERSION }}
else
echo "Building latest version of ${comp}"
./generate_docs
fi
fi
done
- name: Deploying generated docs
Expand All @@ -67,14 +69,16 @@ jobs:
export GIT_VER=$(git describe --always)
export GITHUB_REF_NAME=latest
for comp in `ls components`; do
echo "Deploying latest of ${comp}"
export DOCS_BUILD_DIR=$GITHUB_WORKSPACE/docs/${comp}
export DOCS_DEPLOY_PATH=$DOCS_DEPLOY_PATH_ORIG/${comp}
cd $GITHUB_WORKSPACE/docs/${comp}
deploy-docs
if [ -d $GITHUB_WORKSPACE/docs/${comp} ]; then
echo "Deploying latest of ${comp}"
export DOCS_BUILD_DIR=$GITHUB_WORKSPACE/docs/${comp}
export DOCS_DEPLOY_PATH=$DOCS_DEPLOY_PATH_ORIG/${comp}
cd $GITHUB_WORKSPACE/docs/${comp}
deploy-docs
fi
done;
# Deploy docs with version path
if [[ "${{ env.BUMP_VERSION }}" != "" ]]; then
if [[ "${{ env.BUMP_VERSION }}" != "" ]] && [ -d $GITHUB_WORKSPACE/docs/${comp} ]; then
echo "Deploying specific version of ${comp} (${{ env.BUMP_VERSION }})"
cd $GITHUB_WORKSPACE/docs/${{ env.BUMP_COMPONENT }}
export GITHUB_REF_NAME=${{ env.BUMP_VERSION }}
Expand Down
8 changes: 8 additions & 0 deletions components/console_simple_init/.cz.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
commitizen:
bump_message: 'bump(console_simple_init): $current_version -> $new_version'
pre_bump_hooks: python ../../ci/changelog.py console_simple_init
tag_format: console_simple_init-v$version
version: 0.0.1
version_files:
- idf_component.yml
9 changes: 9 additions & 0 deletions components/console_simple_init/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Changelog

## [0.0.1]()


### Features

- Added simple component for console initialization
- Added check to allow publishing of a component without docs
4 changes: 2 additions & 2 deletions components/console_simple_init/idf_component.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
version: 1.0.0
url: https://github.com/espressif/esp-protocols/tree/master/components/console_simple_init
version: 0.0.1
description: The component provides helper functions for easy initialization and start of esp console.
url: https://github.com/espressif/esp-protocols/tree/master/components/console_simple_init
dependencies:
idf:
version: '>=5.0'

0 comments on commit 19dafb8

Please sign in to comment.