Skip to content

Commit c52cf57

Browse files
committed
feat: update url and unneccessary readme stuff
1 parent e246b7f commit c52cf57

File tree

3 files changed

+12
-19
lines changed

3 files changed

+12
-19
lines changed

.github/workflows/static.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
- name: Install public-hello
5151
run: |
5252
python -m pip install --upgrade pip
53-
pip install public-hello --extra-index-url https://astariul.github.io/github-hosted-pypi/
53+
pip install public-hello --extra-index-url https://pypi.korewa.li/
5454
5555
# Check if the package and its dependency was installed
5656
pip show public-hello
@@ -61,7 +61,7 @@ jobs:
6161
- name: Install public-hello older version
6262
run: |
6363
python -m pip install --upgrade pip
64-
pip install public-hello==0.1 --extra-index-url https://astariul.github.io/github-hosted-pypi/
64+
pip install public-hello==0.1 --extra-index-url https://pypi.korewa.li/
6565
6666
# Check if the package was installed
6767
pip show public-hello

README.md

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@ _While the PyPi index is public, private packages indexed here are kept private
3838

3939
## Try it !
4040

41-
Visit [astariul.github.io/github-hosted-pypi/](http://astariul.github.io/github-hosted-pypi/) and try to install packages indexed there !
41+
Visit [pypi.korewa.li](http://pypi.korewa.li/) and try to install packages indexed there !
4242

4343
---
4444

4545
Try to install the package `public-hello` :
4646
```console
47-
pip install public-hello --extra-index-url https://astariul.github.io/github-hosted-pypi/
47+
pip install public-hello --extra-index-url https://pypi.korewa.li/
4848
```
4949

5050
It will also install the package `mydependency`, automatically !
@@ -59,27 +59,20 @@ print(hi())
5959
You can also install a specific version :
6060

6161
```console
62-
pip install public-hello==0.1 --extra-index-url https://astariul.github.io/github-hosted-pypi/
62+
pip install public-hello==0.1 --extra-index-url https://pypi.korewa.li/
6363
```
6464

6565
---
6666

6767
Now try to install the package `private-hello` :
6868
```console
69-
pip install private-hello --extra-index-url https://astariul.github.io/github-hosted-pypi/
69+
pip install private-hello --extra-index-url https://pypi.korewa.li/
7070
```
7171

7272
_It will not work, because it's private and only me can access it !_
7373

7474
## Get started
7575

76-
* Use this template and create your own repository :
77-
78-
<p align="center">
79-
<a href="https://github.com/astariul/github-hosted-pypi/generate"><img src="https://img.shields.io/badge/%20-Use%20this%20template-green?style=for-the-badge&color=347d39" alt="Use template" /></a>
80-
</p>
81-
82-
* Go to `Settings` of your repository, and enable Github Page
8376
* Customize `index.html` and `pkg_template.html` to your liking
8477
* You're ready to go ! Visit `<user>.github.io/<repo_name>` to see your PyPi index
8578

@@ -112,10 +105,10 @@ If you wonder more specifically about supply chain attacks, check [the section a
112105

113106
#### Q. What happen behind the scenes ?
114107

115-
When running `pip install <package_name> --extra-index-url https://astariul.github.io/github-hosted-pypi/`, the following happen :
108+
When running `pip install <package_name> --extra-index-url https://pypi.korewa.li/`, the following happen :
116109

117110
1. `pip` will look at `https://pypi.org/`, the default, public index, trying to find a package with the specified name.
118-
2. If it can't find, it will look at `https://astariul.github.io/github-hosted-pypi/`.
111+
2. If it can't find, it will look at `https://pypi.korewa.li/`.
119112
3. If the package is found there, the link of the package is returned to `pip` (`git+<repo_link>@<tag>`).
120113
4. From this link, `pip` understand it's a Github repository and will clone the repository (at the specific tag) locally.
121114
5. From the cloned repository, `pip` install the package.
@@ -138,7 +131,7 @@ To do this :
138131
You can just specify a different name for your indexed package. Just give it a different name in the form when registering it.
139132

140133
For example if you have a private package named `tensorflow`, when you register it in this index, you can name it `my_cool_tensorflow`, so there is no name-collision with the public package `tensorflow`.
141-
Then you can install it with `pip install my_cool_tensorflow --extra-index-url https://astariul.github.io/github-hosted-pypi/`.
134+
Then you can install it with `pip install my_cool_tensorflow --extra-index-url https://pypi.korewa.li/`.
142135

143136
Then from `python`, you can just do :
144137
```python
@@ -174,7 +167,7 @@ Let's name this file `gh_auth.txt`.
174167
# syntax=docker/dockerfile:experimental
175168
FROM python:3
176169

177-
RUN --mount=type=secret,id=gh_auth,dst=/root/.netrc pip install <package_name> --extra-index-url https://astariul.github.io/github-hosted-pypi/
170+
RUN --mount=type=secret,id=gh_auth,dst=/root/.netrc pip install <package_name> --extra-index-url https://pypi.korewa.li/
178171
```
179172

180173
**Step 3** : Build your Docker image, specifying the location of the secret created in step 1 :
@@ -200,7 +193,7 @@ While this repository makes it very convenient to have your own PyPi index, be a
200193

201194
That's why we included automated checks into this private PyPi index. Whenever you access the page of your package, PyPi API is called, and if a package with the same name and a higher version is found, the install command is replaced with a warning.
202195

203-
You can see a demo of such warning at [https://astariul.github.io/github-hosted-pypi/transformers/](https://astariul.github.io/github-hosted-pypi/transformers/).
196+
You can see a demo of such warning at [https://pypi.korewa.li/transformers/](https://pypi.korewa.li/transformers/).
204197

205198
If you see this warning, don't install the package ! Instead, change the name of your package or upgrade the version above its public counterpart.
206199

pkg_template.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
</pre>
6060

6161
<pre id='installcmd'>
62-
<code>pip install _package_name --extra-index-url https://astariul.github.io/github-hosted-pypi/</code>
62+
<code>pip install _package_name --extra-index-url https://pypi.korewa.li/</code>
6363
</pre>
6464

6565
<hr />

0 commit comments

Comments
 (0)