Skip to content

Commit

Permalink
Updated deps & using pre-commit action
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnPreston committed Aug 7, 2023
1 parent d774728 commit 01a32ad
Show file tree
Hide file tree
Showing 8 changed files with 557 additions and 422 deletions.
2 changes: 1 addition & 1 deletion .cicd/build_images.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@


version: 0.2
env:
shell: /bin/bash
Expand Down
2 changes: 1 addition & 1 deletion .cicd/buildspec_docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@


version: 0.2
env:
shell: /bin/bash
Expand Down
File renamed without changes.
File renamed without changes.
14 changes: 14 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: pre-commit

on:
pull_request:
push:
branches: [main]

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
- uses: pre-commit/[email protected]
5 changes: 3 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ repos:
- id: check-case-conflict
- id: check-json
- id: check-yaml
exclude: .cicd/*.template
- id: check-toml
- id: end-of-file-fixer
- id: trailing-whitespace
Expand All @@ -16,14 +17,14 @@ repos:
- id: fix-byte-order-marker

- repo: https://github.com/asottile/pyupgrade
rev: v3.8.0
rev: v3.10.1
hooks:
- id: pyupgrade
args: [ "--py38-plus" ]
exclude: ^ecs_files_composer/input.py|docs/

- repo: https://github.com/psf/black
rev: 23.3.0
rev: 23.7.0
hooks:
- id: black
- repo: https://github.com/pycqa/isort
Expand Down
46 changes: 28 additions & 18 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
import os
import sys

sys.path.insert(0, os.path.abspath('..'))
sys.path.insert(0, os.path.abspath(".."))

import ecs_files_composer

Expand All @@ -32,22 +32,22 @@

# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode']
extensions = ["sphinx.ext.autodoc", "sphinx.ext.viewcode"]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
templates_path = ["_templates"]

# The suffix(es) of source filenames.
# You can specify multiple suffix as a list of string:
#
# source_suffix = ['.rst', '.md']
source_suffix = '.rst'
source_suffix = ".rst"

# The master toctree document.
master_doc = 'index'
master_doc = "index"

# General information about the project.
project = 'ECS Files Composer'
project = "ECS Files Composer"
copyright = "2021, John Preston"
author = "John Preston"

Expand All @@ -70,10 +70,10 @@
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This patterns also effect to html_static_path and html_extra_path
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'
pygments_style = "sphinx"

# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos = False
Expand Down Expand Up @@ -137,14 +137,16 @@
# 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']
html_static_path = ["_static"]
html_show_sourcelink = True
html_sidebars = {"**": ["logo-text.html", "globaltoc.html", "localtoc.html", "searchbox.html"]}
html_sidebars = {
"**": ["logo-text.html", "globaltoc.html", "localtoc.html", "searchbox.html"]
}

# -- Options for HTMLHelp output ---------------------------------------

# Output file base name for HTML help builder.
htmlhelp_basename = 'ecs_files_composerdoc'
htmlhelp_basename = "ecs_files_composerdoc"


# -- Options for LaTeX output ------------------------------------------
Expand All @@ -168,14 +170,22 @@
# (source start file, target name, title, author, documentclass
# [howto, manual, or own class]).
latex_documents = [
(master_doc, 'ecs_files_composer.tex', 'ECS Files Composer Documentation', 'John Preston', 'manual'),
(
master_doc,
"ecs_files_composer.tex",
"ECS Files Composer Documentation",
"John Preston",
"manual",
),
]

# -- Options for manual page output ------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [(master_doc, 'ecs_files_composer', 'ECS Files Composer Documentation', [author], 1)]
man_pages = [
(master_doc, "ecs_files_composer", "ECS Files Composer Documentation", [author], 1)
]

# -- Options for Texinfo output ----------------------------------------

Expand All @@ -185,11 +195,11 @@
texinfo_documents = [
(
master_doc,
'ecs_files_composer',
'ECS Files Composer Documentation',
"ecs_files_composer",
"ECS Files Composer Documentation",
author,
'ecs_files_composer',
'One line description of project.',
'Miscellaneous',
"ecs_files_composer",
"One line description of project.",
"Miscellaneous",
),
]
Loading

0 comments on commit 01a32ad

Please sign in to comment.