mirror of
				https://github.com/python-kasa/python-kasa.git
				synced 2025-10-31 04:31:54 +00:00 
			
		
		
		
	Speed up and simplify github workflows (#1128)
- Enable parallel tests in the CI with pytest-xdist - Migrate to the official `astral-sh/setup-uv` github action - Call `pre-commit` run as a single job in CI instead of relisting each check - Use `uv` version 0.4.16 - Fix bug with pre-commit cache - Update `publish.yml` to use `astral-sh/setup-uv`
This commit is contained in:
		
							
								
								
									
										16
									
								
								.github/workflows/publish.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										16
									
								
								.github/workflows/publish.yml
									
									
									
									
										vendored
									
									
								
							| @@ -4,7 +4,8 @@ on: | ||||
|     types: [published] | ||||
|  | ||||
| env: | ||||
|   UV_VERSION: 0.4.5 | ||||
|   UV_VERSION: 0.4.16 | ||||
|   PYTHON_VERSION: 3.12 | ||||
|  | ||||
| jobs: | ||||
|   build-n-publish: | ||||
| @@ -14,16 +15,19 @@ jobs: | ||||
|       id-token: write | ||||
|  | ||||
|     steps: | ||||
|     - uses: actions/checkout@master | ||||
|     - name: Checkout source files | ||||
|       uses: actions/checkout@v4 | ||||
|  | ||||
|     - name: Install uv | ||||
|       uses: astral-sh/setup-uv@v3 | ||||
|  | ||||
|     - name: Setup python | ||||
|       uses: actions/setup-python@v4 | ||||
|       with: | ||||
|         python-version: "3.x" | ||||
|         python-version: ${{ env.PYTHON_VERSION }} | ||||
|  | ||||
|     - name: Install uv | ||||
|       run: |- | ||||
|         pipx install uv==${{ env.UV_VERSION }} --python "${{ steps.setup-python.outputs.python-path }}" | ||||
|     - name: Build a binary wheel and a source tarball | ||||
|       run: uv build | ||||
|  | ||||
|     - name: Publish release on pypi | ||||
|       uses: pypa/gh-action-pypi-publish@release/v1 | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Steven B.
					Steven B.