Readme update

This commit is contained in:
Maxim Khomutov 2022-03-16 02:37:05 +03:00
parent db09bba5b3
commit 1cb2fffcd5
3 changed files with 84 additions and 1 deletions

View File

@ -0,0 +1,40 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="180.5" height="28" role="img" aria-label="MADE WITH: MAGIC">
<title>MADE WITH: MAGIC</title>
<g shape-rendering="crispEdges">
<rect width="100.25" height="28" fill="#555"/>
<rect x="100.25" width="80.25" height="28" fill="#fe7d37"/>
</g>
<g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="100">
<svg x="3"
y="4"
id="Capa_1"
height="20"
viewBox="0 0 512 512"
width="20"
xmlns="http://www.w3.org/2000/svg">
<g>
<path d="m395.82 182.616-188.72 188.72-12.91 1.72-9.35 20.54-34.31 34.31-11.01-.73-11.25 22.99-56.48 56.48c-2.93 2.93-6.77 4.39-10.61 4.39s-7.68-1.46-10.61-4.39l-22.62-22.62h-.01l-22.62-22.63c-5.86-5.86-5.86-15.36 0-21.22l77.63-77.63 16.6-7.03 5.66-15.23 34.31-34.31 14.84-4.92 7.42-17.34 167.57-167.57 33.24 33.24z" fill="#f66"/>
<path d="m395.82 116.146v66.47l-188.72 188.72-12.91 1.72-9.35 20.54-34.31 34.31-11.01-.73-11.25 22.99-56.48 56.48c-2.93 2.93-6.77 4.39-10.61 4.39s-7.68-1.46-10.61-4.39l-22.62-22.62 334.64-334.64z" fill="#e62e6b"/>
<path d="m506.61 209.006-69.14-69.13 43.05-88.38c2.8-5.75 1.65-12.65-2.88-17.17-4.52-4.53-11.42-5.68-17.17-2.88l-88.38 43.05-69.13-69.14c-4.35-4.35-10.92-5.6-16.56-3.16-5.65 2.45-9.23 8.09-9.04 14.24l2.86 90.45-85.37 57.83c-4.91 3.32-7.4 9.22-6.36 15.04 1.04 5.83 5.4 10.51 11.15 11.94l96.62 24.01 24.01 96.62c1.43 5.75 6.11 10.11 11.94 11.15.87.16 1.75.23 2.62.23 4.92 0 9.6-2.42 12.42-6.59l57.83-85.37 90.45 2.86c6.14.19 11.79-3.39 14.24-9.04 2.44-5.64 1.19-12.21-3.16-16.56z" fill="#fabe2c"/>
<path d="m296.26 215.706 24.01 96.62c1.43 5.75 6.11 10.11 11.94 11.15.87.16 1.75.23 2.62.23 4.92 0 9.6-2.42 12.42-6.59l57.83-85.37 90.45 2.86c6.14.19 11.79-3.39 14.24-9.04 2.44-5.64 1.19-12.21-3.16-16.56l-69.14-69.13 43.05-88.38c2.8-5.75 1.65-12.65-2.88-17.17z" fill="#fd9025"/>
<path d="m465 416.966c-25.92 0-47 21.08-47 47s21.08 47 47 47 47-21.08 47-47-21.08-47-47-47z" fill="#fabe2c"/>
<path d="m104 28.966h-13v-13c0-8.284-6.716-15-15-15s-15 6.716-15 15v13h-13c-8.284 0-15 6.716-15 15s6.716 15 15 15h13v13c0 8.284 6.716 15 15 15s15-6.716 15-15v-13h13c8.284 0 15-6.716 15-15s-6.716-15-15-15z" fill="#fed843"/>
<path d="m207.1 371.336-22.26 22.26-45.32-87.62 22.26-22.26z" fill="#fed843"/>
<path d="m184.84 393.596 22.26-22.26-22.66-43.81-22.265 22.265z" fill="#fabe2c"/>
<path d="m150.53 427.906-22.26 22.26-45.32-87.62 22.26-22.26z" fill="#fed843"/>
<path d="m128.27 450.166 22.26-22.26-22.655-43.815-22.26 22.26z" fill="#fabe2c"/>
<circle cx="15" cy="119.969" fill="#5ed8d3" r="15"/>
<circle cx="128" cy="199.969" fill="#d599ed" r="15"/>
<circle cx="192" cy="63.964" fill="#f66" r="15"/>
<circle cx="328" cy="415.967" fill="#31bebe" r="15"/>
<circle cx="440" cy="327.967" fill="#ad77e3" r="14.999"/>
</g>
</svg>
<text transform="scale(.1)" x="600.25" y="175" textLength="590.5" fill="#fff">
MAGIC BY
</text>
<text transform="scale(.1)" x="1400.75" y="175" textLength="700.5" fill="#fff" font-weight="bold">
SantaSpeen
</text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.4 KiB

BIN
.readme_files/preview.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

View File

@ -1,2 +1,45 @@
# gitflic
gitflic api wrapper
<p align="center">
<a href="https://github.com/sssr-dev/api-server/blob/master/LICENSE"><img alt="GitHub license" src="https://img.shields.io/github/license/sssr-dev/api-server?style=for-the-badge"></a>
<a href="https://github.com/sssr-dev/api-server/stargazers"><img alt="GitHub stars" src="https://img.shields.io/github/stars/sssr-dev/api-server?style=for-the-badge"></a>
<a href="https://github.com/SantaSpeen"><img src="https://github.com/SantaSpeen/gitflic/blob/master/.readme_files/magic_logo.svg" alt="magic"></a>
<br/>
<a href="./examples/auth_with_token_and_reg_call.py">
<img src="https://github.com/SantaSpeen/gitflic/blob/master/.readme_files/preview.png" alt="preview ds">
</a>
<br/>
</p>
### Installation
Install via pip:
`pip install gitflic`
### Example:
All examples in [examples](./examples) dir.
```python
from gitflic import Gitflic, GitflicAuth
token = "token_here" # https://gitflic.ru/settings/oauth/token/create
gf_session = GitflicAuth(token)
gf = Gitflic(gf_session)
me_call = gf.call("/user/me")
print(me_call)
# Register call
gf.user = gf.reg_call("/user")
# Request "https://api.gitflic.ru/user/me"
me_with_reg = gf.user("/me")
print(me_with_reg)
print("Is me_with_reg equals me_call:", me_with_reg == me_call)
# Request "https://api.gitflic.ru/user/a4189db1-3e4f-4c2e-8adf-19c58c28e61f"
author = gf.user("/a4189db1-3e4f-4c2e-8adf-19c58c28e61f")
print("\nAuthor: ", author)
```