Compare commits

..

No commits in common. "a534a3b691b3062726f8ae792da3ef50391ec0c2" and "1417c5200724996777e55721ae3a2aa7ed3f9e65" have entirely different histories.

7 changed files with 86 additions and 98 deletions

16
.coveragerc Normal file
View file

@ -0,0 +1,16 @@
[run]
source = ./src/newsreader/
omit =
**/tests/**
**/migrations/**
**/conf/**
**/apps.py
**/admin.py
**/tests.py
**/urls.py
**/wsgi.py
**/celery.py
**/__init__.py
[html]
directory = coverage

View file

@ -1,25 +0,0 @@
# https://editorconfig.org
# top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
trim_trailing_whitespace = true
[*.py]
indent_style = space
indent_size = 4
[*.{yaml,yml,toml,md}]
indent_style = space
indent_size = 2
[Dockerfile*]
indent_style = space
indent_size = 4
[*.json]
indent_style = space
indent_size = 2

12
.isort.cfg Normal file
View file

@ -0,0 +1,12 @@
[settings]
include_trailing_comma = true
line_length = 88
multi_line_output = 3
skip = env/, venv/
default_section = THIRDPARTY
known_first_party = newsreader
known_django = django
sections = FUTURE,STDLIB,DJANGO,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
lines_between_types=1
lines_after_imports=2
lines_between_types=1

10
.prettierrc.json Normal file
View file

@ -0,0 +1,10 @@
{
"semi": true,
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 90,
"tabWidth": 2,
"useTabs": false,
"bracketSpacing": true,
"arrowParens": "avoid"
}

6
jest.config.js Normal file
View file

@ -0,0 +1,6 @@
module.exports = {
roots: ['src/newsreader/js/tests/'],
clearMocks: true,
coverageDirectory: 'coverage',
};

View file

@ -2,6 +2,7 @@
"name": "newsreader", "name": "newsreader",
"version": "0.5.3", "version": "0.5.3",
"description": "Application for viewing RSS feeds", "description": "Application for viewing RSS feeds",
"main": "index.js",
"scripts": { "scripts": {
"lint": "npx prettier \"src/newsreader/js/**/*.js\" --check", "lint": "npx prettier \"src/newsreader/js/**/*.js\" --check",
"format": "npx prettier \"src/newsreader/js/**/*.js\" --write", "format": "npx prettier \"src/newsreader/js/**/*.js\" --write",
@ -13,7 +14,7 @@
}, },
"repository": { "repository": {
"type": "git", "type": "git",
"url": "forgejo.fudiggity.nl:sonny/newsreader" "url": "[git@git.fudiggity.nl:5000]:sonny/newsreader.git"
}, },
"author": "Sonny", "author": "Sonny",
"license": "GPL-3.0-or-later", "license": "GPL-3.0-or-later",
@ -54,22 +55,5 @@
"webpack": "^5.94.0", "webpack": "^5.94.0",
"webpack-cli": "^5.1.4", "webpack-cli": "^5.1.4",
"webpack-merge": "^4.2.2" "webpack-merge": "^4.2.2"
},
"prettier": {
"semi": true,
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 90,
"tabWidth": 2,
"useTabs": false,
"bracketSpacing": true,
"arrowParens": "avoid"
},
"jest": {
"roots": [
"src/newsreader/js/tests/"
],
"clearMocks": true,
"coverageDirectory": "coverage"
} }
} }

View file

@ -1,81 +1,66 @@
[project] [project]
name = "newsreader" name = 'newsreader'
version = "0.5.3" version = '0.5.3'
authors = [{ name = "Sonny" }] authors = [{ name = 'Sonny', email= 'sonny871@hotmail.com' }]
license = { text = "GPL-3.0" } license = {text = 'GPL-3.0'}
requires-python = ">=3.11" requires-python = '>=3.11'
dependencies = [ dependencies = [
"django~=4.2", 'django~=4.2',
"celery~=5.4", 'celery~=5.4',
"psycopg", 'psycopg',
"django-axes", 'django-axes',
"django-celery-beat~=2.7.0", 'django-celery-beat~=2.7.0',
"django-rest-framework", 'django-rest-framework',
"djangorestframework-camel-case", 'djangorestframework-camel-case',
"pymemcache", 'pymemcache',
"python-dotenv~=1.0.1", 'python-dotenv~=1.0.1',
"ftfy~=6.2", 'ftfy~=6.2',
"requests", 'requests',
"feedparser", 'feedparser',
"bleach", 'bleach',
"beautifulsoup4", 'beautifulsoup4',
"lxml", 'lxml',
] ]
[dependency-groups] [dependency-groups]
test-tools = ["ruff", "factory_boy", "freezegun"] test-tools = ['ruff', 'factory_boy', 'freezegun']
development = [ development = [
"django-debug-toolbar", 'django-debug-toolbar',
"django-stubs", 'django-stubs',
"django-extensions", 'django-extensions',
] ]
ci = ["coverage~=7.6.1"] ci = ['coverage~=7.6.1']
production = ["gunicorn~=23.0"] production = ['gunicorn~=23.0']
[project.optional-dependencies] [project.optional-dependencies]
sentry = ["sentry-sdk~=2.0"] sentry = ['sentry-sdk~=2.0']
[tool.uv] [tool.uv]
environments = ["sys_platform == "linux""] environments = ["sys_platform == 'linux'"]
default-groups = ["test-tools"] default-groups = ['test-tools']
[tool.ruff] [tool.ruff]
include = ["pyproject.toml", "src/**/*.py"] include = ['pyproject.toml', 'src/**/*.py']
line-length = 88 line-length = 88
[tool.ruff.lint] [tool.ruff.lint]
select = ["E4", "E7", "E9", "F", "I"] select = ['E4', 'E7', 'E9', 'F', 'I']
[tool.ruff.lint.isort] [tool.ruff.lint.isort]
lines-between-types=1 lines-between-types=1
lines-after-imports=2 lines-after-imports=2
default-section = "third-party" default-section = 'third-party'
known-first-party = ["transip_client"] known-first-party = ['transip_client']
section-order = [ section-order = [
"future", 'future',
"standard-library", 'standard-library',
"django", 'django',
"third-party", 'third-party',
"first-party", 'first-party',
"local-folder", 'local-folder',
] ]
[tool.ruff.lint.isort.sections] [tool.ruff.lint.isort.sections]
django = ["django"] django = ['django']
[tool.coverage.run]
source = ["./src/newsreader/"]
omit = [
"**/tests/**"
"**/migrations/**",
"**/conf/**",
"**/apps.py",
"**/admin.py",
"**/tests.py",
"**/urls.py",
"**/wsgi.py",
"**/celery.py",
"**/__init__.py
]