オンライン画像共有「Imgur」を使用できる「pyimgur」のインストール

スポンサーリンク

【Python】オンライン画像共有「Imgur」を使用できる「pyimgur」のインストールについて解説しています。

「Imgur(https://github.com/Damgaard/PyImgur)」は、オンライン画像共有サービスである「Imgur」に画像をアップロードしたり、ダウンロードすることや、コメントを読むことなどができるライブラリです。

■Python

今回のPythonのバージョンは、「3.8.5」を使用しています。(Windows10)(pythonランチャーでの確認)

■Imgurをインストールする

Imgurをインストールを行いますが、今回はpipを経由してインストールを行うので、まずWindowsのコマンドプロンプトを起動します。

pip install pyimgur

起動後、上記のコマンドを入力し、Enterキーを押します。

なお、今回は、pythonランチャーを使用しており、Python Version 3.8.5にインストールを行うために、バージョンの切り替えを行います。

py -3.8 -m pip install pyimgur

切り替えるために、上記のコマンドを入力し、Enterキーを押します。

Defaulting to user installation because normal site-packages is not writeable
Collecting pyimgur
Downloading pyimgur-0.6.0.tar.gz (33 kB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: requests in c:\users\user_\appdata\roaming\python\python38\site-packages (from pyimgur) (2.26.0)
Requirement already satisfied: idna<4,>=2.5 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests->pyimgur) (3.2)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests->pyimgur) (1.26.6)
Requirement already satisfied: charset-normalizer~=2.0.0 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests->pyimgur) (2.0.2)
Requirement already satisfied: certifi>=2017.4.17 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests->pyimgur) (2021.5.30)
Building wheels for collected packages: pyimgur
Building wheel for pyimgur (setup.py) ... done
Created wheel for pyimgur: filename=pyimgur-0.6.0-py3-none-any.whl size=32423 sha256=56eb1aca2ec41b34c12e97e5526f1a0ca2ef910c83af2971a2de7e6f981a8eae
Stored in directory: c:\users\user_\appdata\local\pip\cache\wheels\c1\e5eaa2e180e5601aac5554057a29714f91a058a68396e943f0
Successfully built pyimgur
Installing collected packages: pyimgur
Successfully installed pyimgur-0.6.0

Enterキーを押すと、インストールが開始され、上記のように「Successfully installed」と表示されます。これが表示されれば、pyimgurが正常にインストールされたことになります。

なお、今回はpyimgurのバージョン0.6.0をインストールしました。

コメント

タイトルとURLをコピーしました