diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 26444a3c..f5512345 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -10,9 +10,8 @@ Want to contribute? Great. Please review the following guidelines carefully and 4. [Contributing code and features](#contributing-code-and-features) 5. [Contributing new documentations](#contributing-new-documentations) 6. [Updating existing documentations](#updating-existing-documentations) -7. [Other contributions](#other-contributions) -8. [Coding conventions](#coding-conventions) -9. [Questions?](#questions) +7. [Coding conventions](#coding-conventions) +8. [Questions?](#questions) ## Reporting bugs diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index c0dfddfc..88ac89f9 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -1,6 +1,6 @@ --- name: Bug report -about: Create a report to help us improve Devdocs +about: Create a report to help us improve DevDocs title: '' labels: 'bug' assignees: '' @@ -34,7 +34,7 @@ encountered it ## More resources ## Possible fix diff --git a/.github/ISSUE_TEMPLATE/documentation_bug.md b/.github/ISSUE_TEMPLATE/documentation_bug.md index 9160c071..5f56d098 100644 --- a/.github/ISSUE_TEMPLATE/documentation_bug.md +++ b/.github/ISSUE_TEMPLATE/documentation_bug.md @@ -24,7 +24,7 @@ Add a description about how the documentation should be ## Actual style ## Expected style diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index a496a10d..664a6540 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -13,7 +13,7 @@ If possible fill each section # Feature request ## Examples diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index f8bc6637..c93bfc45 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -16,13 +16,13 @@ If you’re adding a new scraper, please ensure that you have: - [ ] `16@2x.png`: a 32×32 pixel icon for the doc - [ ] `SOURCE`: A text file containing the URL to the page the image can be found on or the URL of the original image itself - + -If you're updating an existing documentation to it's latest version, please ensure that you have: +If you're updating existing documentation to its latest version, please ensure that you have: - [ ] Updated the versions and releases in the scraper file -- [ ] Ensured the license is up-to-date and that the documentation's entry in the array in `about_tmpl.coffee` matches it's data in `self.attribution` +- [ ] Ensured the license is up-to-date and that the documentation's entry in the array in `about_tmpl.coffee` matches its data in `self.attribution` - [ ] Ensured the icons and the `SOURCE` file in public/icons/*your_scraper_name*/ are up-to-date if the documentation has a custom icon - [ ] Ensured `self.links` contains up-to-date urls if `self.links` is defined - [ ] Tested the changes locally to ensure: diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f8f9ba61..ad547735 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,9 +11,9 @@ jobs: runs-on: ubuntu-20.04 if: github.repository == 'freeCodeCamp/devdocs' steps: - - uses: actions/checkout@v2.3.4 + - uses: actions/checkout@v2.4.2 - name: Set up Ruby - uses: ruby/setup-ruby@v1.81.0 + uses: ruby/setup-ruby@v1.110.0 with: bundler-cache: true # runs 'bundle install' and caches installed gems automatically - name: Run tests diff --git a/.github/workflows/schedule-doc-report.yml b/.github/workflows/schedule-doc-report.yml index e7ba7d6d..b90a3098 100644 --- a/.github/workflows/schedule-doc-report.yml +++ b/.github/workflows/schedule-doc-report.yml @@ -8,9 +8,9 @@ jobs: runs-on: ubuntu-20.04 if: github.repository == 'freeCodeCamp/devdocs' steps: - - uses: actions/checkout@v2.3.4 + - uses: actions/checkout@v2.4.2 - name: Set up Ruby - uses: ruby/setup-ruby@v1.81.0 + uses: ruby/setup-ruby@v1.110.0 with: bundler-cache: true # runs 'bundle install' and caches installed gems automatically - name: Generate report diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 01eacfb4..7b7801dc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,9 +9,9 @@ jobs: test: runs-on: ubuntu-20.04 steps: - - uses: actions/checkout@v2.3.4 + - uses: actions/checkout@v2.4.2 - name: Set up Ruby - uses: ruby/setup-ruby@v1.81.0 + uses: ruby/setup-ruby@v1.110.0 with: bundler-cache: true # runs 'bundle install' and caches installed gems automatically - name: Run tests diff --git a/.gitignore b/.gitignore index 8f06d308..bbf749a4 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,7 @@ public/docs/**/* docs/**/* !docs/*.md /vendor +*.tar +*.tar.bz2 +*.tar.gz +*.zip diff --git a/.ruby-version b/.ruby-version index a4dd9dba..49cdd668 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.7.4 +2.7.6 diff --git a/Dockerfile b/Dockerfile index 35b84a2e..060193df 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.7.4 +FROM ruby:2.7.6 ENV LANG=C.UTF-8 ENV ENABLE_SERVICE_WORKER=true diff --git a/Gemfile.lock b/Gemfile.lock index 85015b88..f91f2685 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -7,7 +7,7 @@ GEM minitest (~> 5.1) tzinfo (~> 1.1) backports (3.15.0) - better_errors (2.5.1) + better_errors (2.9.1) coderay (>= 1.0.0) erubi (>= 1.0.0) rack (>= 0.9.0) @@ -20,13 +20,13 @@ GEM coffee-script-source (1.12.2) concurrent-ruby (1.1.9) daemons (1.4.0) - erubi (1.9.0) + erubi (1.10.0) ethon (0.12.0) ffi (>= 1.3.0) eventmachine (1.2.7) execjs (2.7.0) exifr (1.3.6) - ffi (1.12.2) + ffi (1.15.5) fspath (3.1.2) highline (2.0.3) html-pipeline (2.12.0) @@ -46,16 +46,18 @@ GEM image_size (2.0.2) in_threads (1.5.3) method_source (1.0.0) - mini_portile2 (2.4.0) + mini_portile2 (2.8.0) minitest (5.14.4) multi_json (1.13.1) - mustermann (1.0.3) + mustermann (1.1.1) + ruby2_keywords (~> 0.0.1) net-sftp (3.0.0.beta1) net-ssh (>= 5.0.0, < 6.0.0) net-ssh (5.2.0) newrelic_rpm (6.7.0.359) - nokogiri (1.10.4) - mini_portile2 (~> 2.4.0) + nokogiri (1.13.6) + mini_portile2 (~> 2.8.0) + racc (~> 1.4) options (2.3.2) progress (3.5.2) progress_bar (1.3.0) @@ -64,7 +66,8 @@ GEM pry (0.14.1) coderay (~> 1.1) method_source (~> 1.0) - rack (2.2.3) + racc (1.6.0) + rack (2.2.3.1) rack-protection (2.0.7) rack rack-ssl-enforcer (0.2.9) @@ -75,6 +78,7 @@ GEM rb-inotify (0.10.0) ffi (~> 1.0) rr (1.2.1) + ruby2_keywords (0.0.5) sass (3.7.4) sass-listen (~> 4.0.0) sass-listen (4.0.0) @@ -128,7 +132,7 @@ GEM unicode-display_width (1.6.0) unicode_utils (1.4.0) unix_utils (0.0.15) - yajl-ruby (1.4.1) + yajl-ruby (1.4.3) PLATFORMS ruby diff --git a/README.md b/README.md index 5fba337f..f7788a8b 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ Unless you wish to contribute to the project, we recommend using the hosted vers DevDocs is made of two pieces: a Ruby scraper that generates the documentation and metadata, and a JavaScript app powered by a small Sinatra app. -DevDocs requires Ruby 2.6.x, libcurl, and a JavaScript runtime supported by [ExecJS](https://github.com/rails/execjs#readme) (included in OS X and Windows; [Node.js](https://nodejs.org/en/) on Linux). Once you have these installed, run the following commands: +DevDocs requires Ruby 2.7.4, libcurl, and a JavaScript runtime supported by [ExecJS](https://github.com/rails/execjs#readme) (included in OS X and Windows; [Node.js](https://nodejs.org/en/) on Linux). Once you have these installed, run the following commands: ```sh git clone https://github.com/freeCodeCamp/devdocs.git && cd devdocs @@ -147,8 +147,6 @@ Made something cool? Feel free to open a PR to add a new row to this table! | Project | Description | Last commit | |---------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| [Chrome web app](https://chrome.google.com/webstore/detail/devdocs/mnfehgbmkapmjnhcnbodoamcioleeooe) | Chrome Web App which adds a shortcut to DevDocs apps page. | N/A | -| [Ubuntu Touch app](https://uappexplorer.com/app/devdocsunofficial.berkes) | Application for devices running Ubuntu Touch. | N/A | | [Sublime Text plugin](https://sublime.wbond.net/packages/DevDocs) | Sublime Text plugin to search DevDocs by selection or by input. | [![Latest GitHub commit](https://img.shields.io/github/last-commit/vitorbritto/sublime-devdocs?logo=github&label)](https://github.com/vitorbritto/sublime-devdocs) | | [Atom plugin](https://atom.io/packages/devdocs) | Atom plugin adding the `doc` command to search DevDocs. | [![Latest GitHub commit](https://img.shields.io/github/last-commit/masnun/atom-devdocs?logo=github&label)](https://github.com/masnun/atom-devdocs) | | [gruehle/dev-docs-viewer](https://github.com/gruehle/dev-docs-viewer) | Brackets extension for searching and viewing DevDocs content. | [![Latest GitHub commit](https://img.shields.io/github/last-commit/gruehle/dev-docs-viewer?logo=github&label)](https://github.com/gruehle/dev-docs-viewer) | diff --git a/assets/javascripts/app/settings.coffee b/assets/javascripts/app/settings.coffee index b885fd5e..38b4f910 100644 --- a/assets/javascripts/app/settings.coffee +++ b/assets/javascripts/app/settings.coffee @@ -24,7 +24,12 @@ class app.Settings 'news' ] - LAYOUTS: ['_max-width', '_sidebar-hidden', '_native-scrollbars'] + LAYOUTS: [ + '_max-width' + '_sidebar-hidden' + '_native-scrollbars' + '_text-justify-hyphenate' + ] @defaults: count: 0 @@ -153,7 +158,8 @@ class app.Settings toggleLayout: (layout, enable) -> classList = document.body.classList - classList.toggle(layout, enable) unless app.router?.isSettings + # sidebar is always shown for settings; its state is updated in app.views.Settings + classList.toggle(layout, enable) unless layout is '_sidebar-hidden' and app.router?.isSettings classList.toggle('_overlay-scrollbars', $.overlayScrollbarsEnabled()) return diff --git a/assets/javascripts/lib/page.coffee b/assets/javascripts/lib/page.coffee index 7a5329f6..5ad89b32 100644 --- a/assets/javascripts/lib/page.coffee +++ b/assets/javascripts/lib/page.coffee @@ -200,6 +200,8 @@ page.track = (fn) -> track = -> return unless app.config.env == 'production' + return if navigator.doNotTrack == '1' + return if navigator.globalPrivacyControl consentGiven = Cookies.get('analyticsConsent') consentAsked = Cookies.get('analyticsConsentAsked') diff --git a/assets/javascripts/news.json b/assets/javascripts/news.json index cae61ade..2a9934a9 100644 --- a/assets/javascripts/news.json +++ b/assets/javascripts/news.json @@ -1,4 +1,57 @@ [ + [ + "2022-05-03", + "New documentations: Kubernetes, Kubectl" + ], + [ + "2022-04-25", + "New documentation: Nix" + ], + [ + "2022-03-31", + "New documentation: Eigen3" + ], + [ + "2022-02-21", + "New documentation: Tailwind CSS" + ], + [ + "2022-01-12", + "New documentation: React Router" + ], + [ + "2022-01-09", + "New documentation: Deno" + ], + [ + "2021-12-29", + "New documentation: PointCloudLibrary" + ], + [ + "2021-12-27", + "New documentation: Zig" + ], + [ + "2021-12-26", + "New documentation: GNU Make" + ], + [ + "2021-12-07", + "New documentation: Prettier", + "Renamed documentation: Web APIs" + ], + [ + "2021-12-05", + "New documentation: esbuild" + ], + [ + "2021-12-04", + "New documentation: Vite" + ], + [ + "2021-11-29", + "New documentation: i3" + ], [ "2021-06-09", "New documentation: R" diff --git a/assets/javascripts/templates/pages/about_tmpl.coffee b/assets/javascripts/templates/pages/about_tmpl.coffee index 2fe66d31..ebadb1b3 100644 --- a/assets/javascripts/templates/pages/about_tmpl.coffee +++ b/assets/javascripts/templates/pages/about_tmpl.coffee @@ -30,7 +30,6 @@ app.templates.aboutPage = -> """

Plugins and Extensions