diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index 1ac8fdd4a..000000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,129 +0,0 @@ -version: 2 -jobs: - build: - branches: - ignore: - - gh-pages - - docker: - # a packaged system that has the instructions for creating a running container. - - image: circleci/ruby:2.7.4 - - # actions that need to be taken to perform your job - steps: - - add_ssh_keys: - fingerprints: - - "dc:5f:39:48:00:b4:72:34:e1:d2:c4:e1:1f:d1:e2:ce" #plotlydocbot - - - restore_cache: - keys: - - source-v1- #one time, not every time! - - # checks out the source code for a job over SSH - - checkout - - - save_cache: - key: source-v1-1 # Sept 7, 2019 - paths: - - ".git" - - - restore_cache: - keys: - - gem-cache-v1-{{ arch }}-{{ .Branch }}-{{ checksum "Gemfile.lock" }} - - gem-cache-v1-{{ arch }}-{{ .Branch }} - - gem-cache-v1 - - - run: - name: install dependencies - command: | - sudo apt-get update - sudo apt-get install --allow-unauthenticated debian-archive-keyring - gem install bundler:2.4.22 - bundle install --path vendor/bundle - sudo rm /etc/apt/sources.list - echo "deb http://ftp.us.debian.org/debian/ bookworm main contrib non-free" | sudo tee -a /etc/apt/sources.list - echo "deb-src http://ftp.us.debian.org/debian/ bookworm main contrib non-free" | sudo tee -a /etc/apt/sources.list - echo "Acquire::Check-Valid-Until false;" | sudo tee -a /etc/apt/apt.conf.d/10-nocheckvalid - echo '# Package: *\nPin: origin "archive.debian.org"\nPin-Priority: 500' | sudo tee -a /etc/apt/preferences.d/10-archive-pin - sudo apt-get update - sudo apt-get install python3-full python3-pip - python3 -m venv venv - source venv/bin/activate - pip install PyYAML==6.0.1 - pip install python-frontmatter==0.5.0 - pip install pathlib - - - save_cache: - key: gem-cache-v1-{{ arch }}-{{ .Branch }}-{{ checksum "Gemfile.lock" }} - paths: - - vendor/bundle - - - run: - name: deployment - command: | - source venv/bin/activate - git config --global user.email "accounts@plot.ly" - git config --global user.name "plotlydocbot" - echo - echo "token: ${mapbox_token}" > _data/mapbox_token.yml - make fetch_upstream_files - python front-matter-ci.py _posts - python check-or-enforce-order.py _posts/python - python check-or-enforce-order.py _posts/python-v3 - python check-or-enforce-order.py _posts/r/ - python check-or-enforce-order.py _posts/matlab - python check-or-enforce-order.py _posts/plotly_js - python generate-sitemaps.py - echo `md5 -q all_static/css/main.css` > _data/cache_bust_css.yml - deactivate - rm -rf venv - bundle exec jekyll build - cp python/sitemap.xml _site/python/sitemap.xml - rm _data/mapbox_token.yml - mkdir snapshots - cd _site - cp -r 'all_static' '../snapshots' - cp 'api/index.html' '../snapshots' - cp --parents 'python/index.html' '../snapshots' - cp --parents 'python/getting-started/index.html' '../snapshots' - cp --parents 'python/plotly-fundamentals/index.html' '../snapshots' - cp --parents 'python/line-and-scatter/index.html' '../snapshots' - cp --parents 'r/index.html' '../snapshots' - cp --parents 'r/getting-started/index.html' '../snapshots' - cp --parents 'r/plotly-fundamentals/index.html' '../snapshots' - cp --parents 'r/line-and-scatter/index.html' '../snapshots' - cp --parents 'javascript/index.html' '../snapshots' - cp --parents 'javascript/plotly-fundamentals/index.html' '../snapshots' - cp --parents 'javascript/getting-started/index.html' '../snapshots' - cp --parents 'javascript/line-and-scatter/index.html' '../snapshots' - cp --parents 'ggplot2/index.html' '../snapshots' - cp --parents 'ggplot2/getting-started/index.html' '../snapshots' - cp --parents 'ggplot2/histograms/index.html' '../snapshots' - cp --parents 'matlab/index.html' '../snapshots' - cp --parents 'matlab/getting-started/index.html' '../snapshots' - cp --parents 'matlab/graphing-multiple-chart-types/index.html' '../snapshots' - cp --parents 'matlab/histograms/index.html' '../snapshots' - cp --parents 'csharp/index.html' '../snapshots' - cp --parents 'csharp/getting-started/index.html' '../snapshots' - cd .. - rm -f 'snapshots/all_static/javascripts/jquery-knob/index.html' - rm -f 'snapshots/all_static/images/Plotly-feed2.html' - rm -f 'snapshots/all_static/images/Plotly.html' - rm -f 'snapshots/all_static/images/Plotly-Feed.html' - rm -f snapshots/*.bkp - rm -f snapshots/*/*.bkp - rm -f snapshots/*/*/*.bkp - bundle exec percy snapshot snapshots --enable_javascript - rm -rf 'snapshots/' - if [ "${CIRCLE_BRANCH}" == "master" ]; then - git clone --depth=1 --branch=gh-pages https://github.com/plotly/documentation.git - git config user.name plotlydocbot - git config user.email accounts@plot.ly - cp -r _site/* documentation - cd documentation - git add . - git commit -m "deploying https://github.com/plotly/graphing-library-docs/commit/${CIRCLE_SHA1}" - git push - cd .. - rm -rf documentation - fi diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 000000000..0666bad95 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,121 @@ +name: Build and Deploy + +on: + push: + branches-ignore: + - gh-pages + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v6 + + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: '2.7' + bundler-cache: true + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + + - name: Install uv + uses: astral-sh/setup-uv@v5 + + - name: Install Python dependencies + run: uv pip install --system PyYAML==6.0.1 python-frontmatter==0.5.0 + + - name: Fetch upstream docs + run: make fetch_upstream_files + + - name: Set up Mapbox token + run: | + echo "token: ${{ secrets.MAPBOX_TOKEN }}" > _data/mapbox_token.yml + + - name: Build site + run: | + python front-matter-ci.py _posts + python check-or-enforce-order.py _posts/python + python check-or-enforce-order.py _posts/python-v3 + python check-or-enforce-order.py _posts/r/ + python check-or-enforce-order.py _posts/matlab + python check-or-enforce-order.py _posts/plotly_js + python generate-sitemaps.py + md5sum all_static/css/main.css | cut -d ' ' -f 1 > _data/cache_bust_css.yml + bundle exec jekyll build + cp python/sitemap.xml _site/python/sitemap.xml + rm _data/mapbox_token.yml + + - name: Create Percy snapshots + run: | + mkdir snapshots + cd _site + cp -r 'all_static' '../snapshots' + cp 'api/index.html' '../snapshots' + cp --parents 'python/index.html' '../snapshots' + cp --parents 'python/getting-started/index.html' '../snapshots' + cp --parents 'python/plotly-fundamentals/index.html' '../snapshots' + cp --parents 'python/line-and-scatter/index.html' '../snapshots' + cp --parents 'r/index.html' '../snapshots' + cp --parents 'r/getting-started/index.html' '../snapshots' + cp --parents 'r/plotly-fundamentals/index.html' '../snapshots' + cp --parents 'r/line-and-scatter/index.html' '../snapshots' + cp --parents 'javascript/index.html' '../snapshots' + cp --parents 'javascript/plotly-fundamentals/index.html' '../snapshots' + cp --parents 'javascript/getting-started/index.html' '../snapshots' + cp --parents 'javascript/line-and-scatter/index.html' '../snapshots' + cp --parents 'ggplot2/index.html' '../snapshots' + cp --parents 'ggplot2/getting-started/index.html' '../snapshots' + cp --parents 'ggplot2/histograms/index.html' '../snapshots' + cp --parents 'matlab/index.html' '../snapshots' + cp --parents 'matlab/getting-started/index.html' '../snapshots' + cp --parents 'matlab/graphing-multiple-chart-types/index.html' '../snapshots' + cp --parents 'matlab/histograms/index.html' '../snapshots' + cp --parents 'csharp/index.html' '../snapshots' + cp --parents 'csharp/getting-started/index.html' '../snapshots' + cd .. + rm -f 'snapshots/all_static/javascripts/jquery-knob/index.html' + rm -f 'snapshots/all_static/images/Plotly-feed2.html' + rm -f 'snapshots/all_static/images/Plotly.html' + rm -f 'snapshots/all_static/images/Plotly-Feed.html' + rm -f snapshots/*.bkp snapshots/*/*.bkp snapshots/*/*/*.bkp + + - name: Percy snapshot + run: bundle exec percy snapshot snapshots --enable_javascript + env: + PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }} + + - name: Create GitHub App token + if: github.ref_name == 'master' && github.repository == 'plotly/graphing-library-docs' + uses: actions/create-github-app-token@v2 + id: app-token + with: + app-id: ${{ vars.GRAPHING_LIBRARIES_CI_GHAPP_ID }} + private-key: ${{ secrets.GRAPHING_LIBRARIES_CI_GHAPP_PRIVATE_KEY }} + owner: ${{ github.repository_owner }} + repositories: documentation + + - name: Checkout documentation repo + if: github.ref_name == 'master' && github.repository == 'plotly/graphing-library-docs' + uses: actions/checkout@v4 + with: + repository: plotly/documentation + ref: gh-pages + token: ${{ steps.app-token.outputs.token }} + path: documentation + + - name: Deploy docs + if: github.ref_name == 'master' && github.repository == 'plotly/graphing-library-docs' + run: | + git config --global user.email "accounts@plot.ly" + git config --global user.name "plotlydocbot" + cp -r _site/* documentation/ + cd documentation + git add . + git commit -m "deploying https://github.com/plotly/graphing-library-docs/commit/${{ github.sha }}" || echo "No changes to commit" + git push diff --git a/_posts/plotly_js/fundamentals/annotations/2015-04-09-annotations_plotly_js_index.html b/_posts/plotly_js/fundamentals/annotations/2015-04-09-annotations_plotly_js_index.html index 7a1a1a8b7..6bd595a3f 100755 --- a/_posts/plotly_js/fundamentals/annotations/2015-04-09-annotations_plotly_js_index.html +++ b/_posts/plotly_js/fundamentals/annotations/2015-04-09-annotations_plotly_js_index.html @@ -12,4 +12,4 @@ --- {% assign examples = site.posts | where:"language","plotly_js" | where:"suite","annotations" | sort: "order" %} -{% include posts/auto_examples.html examples=examples %} +{% include posts/auto_examples.html examples=examples %} \ No newline at end of file diff --git a/_posts/plotly_js/fundamentals/plotly-js-3-changes/2024-10-09-plotly-js-3-changes.md b/_posts/plotly_js/fundamentals/plotly-js-3-changes/2024-10-09-plotly-js-3-changes.md index 60e4981f4..e65f22568 100644 --- a/_posts/plotly_js/fundamentals/plotly-js-3-changes/2024-10-09-plotly-js-3-changes.md +++ b/_posts/plotly_js/fundamentals/plotly-js-3-changes/2024-10-09-plotly-js-3-changes.md @@ -11,6 +11,7 @@ redirect_from: javascript/pointcloud/ sitemap: false thumbnail: thumbnail/pointcloud.jpg --- + This page outlines the changes in Plotly.js version 3 and cases where you may need to update your charts. ## Removed Features @@ -359,4 +360,4 @@ var data = [{ cmin: 0, cmax: 100 }]; -``` +``` \ No newline at end of file diff --git a/_posts/plotly_js/fundamentals/static-image-export/2016-05-20-static-image.md b/_posts/plotly_js/fundamentals/static-image-export/2016-05-20-static-image.md index 94282aaad..cf77e1f0d 100644 --- a/_posts/plotly_js/fundamentals/static-image-export/2016-05-20-static-image.md +++ b/_posts/plotly_js/fundamentals/static-image-export/2016-05-20-static-image.md @@ -68,4 +68,4 @@ The common image formats: 'PNG', 'JPG/JPEG' are supported. In addition, formats ## Saving as SVG ## img_svg.attr("src", url); - Plotly.toImage(gd,{format:'svg',height:800,width:800}); + Plotly.toImage(gd,{format:'svg',height:800,width:800}); \ No newline at end of file diff --git a/makefile b/makefile index 621cc60d3..e75298687 100644 --- a/makefile +++ b/makefile @@ -37,11 +37,11 @@ fetch_adjacent_python_files: cp -r ../plotly.py/doc/build/html _posts/python/html fetch_upstream_files: clean - git clone --depth 1 -b built git@github.com:plotly/plotly.py-docs _posts/python/html - git clone --depth 1 -b built git@github.com:plotly/plotlyjs.jl-docs _posts/julia/html - git clone --depth 1 -b built git@github.com:plotly/plotly.net-docs _posts/fsharp/html - git clone --depth 1 -b built git@github.com:plotly/plotly.r-docs _posts/r/md - git clone --depth 1 -b built git@github.com:plotly/plotly.matlab-docs _posts/matlab/md + git clone --depth 1 -b built https://github.com/plotly/plotly.py-docs _posts/python/html + git clone --depth 1 -b built https://github.com/plotly/plotlyjs.jl-docs _posts/julia/html + git clone --depth 1 -b built https://github.com/plotly/plotly.net-docs _posts/fsharp/html + git clone --depth 1 -b built https://github.com/plotly/plotly.r-docs _posts/r/md + git clone --depth 1 -b built https://github.com/plotly/plotly.matlab-docs _posts/matlab/md mv _posts/r/md/ggplot2 _posts/ggplot2/md mv _posts/fsharp/html/csharp _posts/csharp/html