Skip to content

Commit

Permalink
lining
Browse files Browse the repository at this point in the history
  • Loading branch information
AtKristijan committed Dec 21, 2021
1 parent 358400c commit 824407f
Show file tree
Hide file tree
Showing 120 changed files with 7,250 additions and 4,686 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Linting

on: [push, pull_request]

jobs:
pre_job:
name: Path match check
runs-on: ubuntu-latest
# Map a step output to a job output
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@master
with:
github_token: ${{ github.token }}
paths_ignore: '["**.po", "**.json"]'
linting:
name: All file linting
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: pre-commit/[email protected]
46 changes: 27 additions & 19 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,19 +1,27 @@
- repo: git://github.com/pre-commit/pre-commit-hooks
rev: v2.5.0
hooks:
- id: trailing-whitespace
- id: flake8
- id: check-yaml
- id: check-added-large-files
- id: debug-statements
- id: end-of-file-fixer
exclude: '^.+?\.json$'
- repo: git://github.com/asottile/reorder_python_imports
rev: v2.1.0
hooks:
- id: reorder-python-imports
- repo: git://github.com/pre-commit/mirrors-eslint
sha: v3.14.0
hooks:
- id: eslint
additional_dependencies: ['eslint', 'eslint-plugin-html', 'eslint-config-airbnb', 'eslint-plugin-import', 'eslint-plugin-jsx-a11y']
repos:
- repo: git://github.com/pre-commit/pre-commit-hooks
rev: v2.5.0
hooks:
- id: trailing-whitespace
exclude: '^.+?\.template$'
- id: flake8
exclude: '^.+?\.template$'
- id: check-yaml
exclude: '^.+?\.template$'
- id: check-added-large-files
exclude: '^.+?\.template$'
- id: debug-statements
exclude: '^.+?\.template$'
- id: end-of-file-fixer
exclude: '^.+?(\.json|\.template)$'

- repo: git://github.com/asottile/reorder_python_imports
rev: v2.1.0
hooks:
- id: reorder-python-imports
exclude: '^.+?\.template$'
- repo: https://github.com/python/black
rev: 20.8b1
hooks:
- id: black
exclude: '^.+?\.template$'
10 changes: 5 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,33 +80,33 @@ Here are the steps for setting up `ricecooker` for local development:
3. Create a Python virtual environment for this project (optional, but recommended):
* Install the `virtualenv` package using the command
* Install the `virtualenv` package using the command
```
pip install virtualenv
```
* The next steps depends if you're using a UNIX system (Mac/Linux) or Windows:
* For UNIX operating systems:
* Create a virtual env called `venv` in the current directory using the
command:
command:
```
virtualenv -p python3 venv
```
* Activate the virtualenv called `venv` by running:
* Activate the virtualenv called `venv` by running:
```
source venv/bin/activate
```
Your command prompt will change to indicate you're working inside `venv`.
* For Windows systems:
* Create a virtual env called `venv` in the current directory using the
following command:
following command:
```
virtualenv -p C:/Python36/python.exe venv
```
You may need to adjust the `-p` argument depending on where your version
of Python is located. Note you'll need Python version 3.5 or higher.
* Activate the virtualenv called `venv` by running:
* Activate the virtualenv called `venv` by running:
```
.\venv\Scripts\activate
```
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ ricecooker
==========
[![PyPI pyversions](https://img.shields.io/pypi/pyversions/ricecooker.svg)](https://pypi.python.org/pypi/ricecooker/)
[![build](https://github.com/learningequality/ricecooker/actions/workflows/pythontest.yml/badge.svg?branch=master)](https://github.com/learningequality/ricecooker/actions)
[![docs](https://readthedocs.org/projects/ricecooker/badge/?version=latest&style=flat)](https://ricecooker.readthedocs.io/)
[![docs](https://readthedocs.org/projects/ricecooker/badge/?version=latest&style=flat)](https://ricecooker.readthedocs.io/)


The `ricecooker` library is a framework for automating the conversion of educational content into
Kolibri content channels and uploading them to [Kolibri Studio](https://studio.learningequality.org/),
Kolibri content channels and uploading them to [Kolibri Studio](https://studio.learningequality.org/),
which is the central content server for [Kolibri](http://learningequality.org/kolibri/).


Expand Down Expand Up @@ -36,7 +36,7 @@ The basic process of getting new content into Kolibri is as follows:
The diagram below illustrates how content flows within the Kolibri ecosystem
and highlights the part which is covered by the `ricecooker` framework (bottom left).

![Overview of steps for integrating external content sources for use in the Kolibri Learning Platform](docs/figures/content_pipeline_diagram_with_highlight.png)
![Overview of steps for integrating external content sources for use in the Kolibri Learning Platform](docs/figures/content_pipeline_diagram_with_highlight.png)
*External content sources (left) are first uploaded to [Kolibri Studio](https://studio.learningequality.org/) (middle), so they can be used in the [Kolibri Learning Platform](http://learningequality.org/kolibri/) (right).*


Expand All @@ -48,7 +48,7 @@ place to learn about writing automated content integration scripts.

Here are some links to other documents and guides you can read to learn about
the other parts of the Kolibri content platform:

- The [Kolibri Content Integration Guide](https://learningequality.org/r/integration-guide)
is a comprehensive guide to the decisions, processes, and tools for integrating
external content sources for use in the Kolibri Learning Platform.
Expand Down
1 change: 0 additions & 1 deletion docs/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,3 @@ License
:alt: Creative Commons License

This work is licensed under a `Creative Commons Attribution-ShareAlike 4.0 International License <http://creativecommons.org/licenses/by-sa/4.0/>`__

4 changes: 2 additions & 2 deletions docs/_templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
/* div {
border: 1px solid red;
} */

.row {clear: both}

@media (min-width: 800px) {
Expand All @@ -38,7 +38,7 @@
float: left;
}


.column3 {
width: 33.3%;
font-size: 80%;
Expand Down
1 change: 0 additions & 1 deletion docs/chefops.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,4 +141,3 @@ time to complete so it is best to run them on a dedicated server for this purpos
e.g. `./sushichef.py --token=... --thumbnails lang=fr`.
- By default `nohup` logs stderr and stdout output to a file called `nohup.out`
in the current working directory. Use `tail -f nohup.out` to follow this log file.

2 changes: 1 addition & 1 deletion docs/community/authors.rst
2 changes: 1 addition & 1 deletion docs/community/contributing.md
1 change: 0 additions & 1 deletion docs/concepts/reviewing_channels.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,3 @@ You can. Whenever you need a distraction, take 20 minutes and place yourself in
the learner's shoes and go explore the channel on the demo server link provided
on the notion card. If you notice any issues while browsing, add them to the
Issue tracker table. That's it. Learn something today.

1 change: 0 additions & 1 deletion docs/concepts/terminology.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,3 @@ process to Kolibri Studio for review and publishing.
Conceptually, `SushiChef` scripts are very similar to web scrapers,
but with specialized functions for optimizing the content for Kolibri's
data structures and capabilities.

Loading

0 comments on commit 824407f

Please sign in to comment.