├── images ├── example-output-carbon.png └── deadlink-logo-with-text.svg ├── .github └── workflows │ └── ci.yml └── README.md /images/example-output-carbon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mondaytech-dev/deadlink/HEAD/images/example-output-carbon.png -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: ci 2 | 3 | on: 4 | push: 5 | branches: 6 | - main 7 | pull_request: 8 | branches: 9 | - main 10 | 11 | jobs: 12 | lint: 13 | runs-on: ubuntu-latest 14 | steps: 15 | - name: Check out repo 16 | uses: actions/checkout@v2 17 | - name: Set up Python 18 | uses: actions/setup-python@v2 19 | - name: Run pre-commit 20 | uses: pre-commit/action@v2.0.3 21 | 22 | build: 23 | runs-on: ubuntu-latest 24 | strategy: 25 | matrix: 26 | python-version: ["3.7", "3.8", "3.9", "3.10"] 27 | steps: 28 | - uses: actions/setup-python@v2 29 | with: 30 | python-version: ${{ matrix.python-version }} 31 | - uses: actions/checkout@v2 32 | - name: Test with tox 33 | run: | 34 | pip install tox 35 | tox -- --cov deadlink --cov-report xml --cov-report term 36 | - name: Submit to codecov 37 | uses: codecov/codecov-action@v1 38 | if: ${{ matrix.python-version == '3.9' }} 39 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | deadlink 3 |

4 | 5 | [![PyPi Version](https://img.shields.io/pypi/v/deadlink.svg?style=flat-square)](https://pypi.org/project/deadlink/) 6 | [![PyPI pyversions](https://img.shields.io/pypi/pyversions/deadlink.svg?style=flat-square)](https://pypi.org/project/deadlink/) 7 | [![GitHub stars](https://img.shields.io/github/stars/mondaytech-dev/deadlink.svg?style=flat-square&logo=github&label=Stars&logoColor=white)](https://github.com/mondaytech-dev/deadlink/) 8 | [![Downloads](https://static.pepy.tech/badge/deadlink/month?style=flat-square)](https://pepy.tech/projects/deadlink) 9 | 10 | Parses text files for HTTP URLs and checks if they are still valid. Install with 11 | 12 | ``` 13 | pip install deadlink 14 | ``` 15 | 16 | and use as 17 | 18 | ```sh 19 | deadlink check README.md # or multiple files/directories 20 | # or deadlink c README.md 21 | ``` 22 | 23 | You can configure deadlink via its config file 24 | `~/.config/deadlink/deadlink.toml`, e.g., 25 | 26 | ```toml 27 | timeout_s = 10 28 | cache_ttl_s = 259200 29 | num_concurrent_requests = 5 30 | # allow_file_extensions = ["txt", "yaml", "c"] 31 | ignore_hosts = ["www.example.com"] 32 | ``` 33 | 34 | Example output: 35 | 36 | 37 | 38 | ![](https://raw.githubusercontent.com/mondaytech-dev/deadlink/refs/heads/main/images/example-output-carbon.png) 39 | -------------------------------------------------------------------------------- /images/deadlink-logo-with-text.svg: -------------------------------------------------------------------------------- 1 | --------------------------------------------------------------------------------