mirror of
https://github.com/instaloader/instaloader.git
synced 2024-09-11 16:22:24 +02:00
Minor documentation fixes
This commit is contained in:
parent
5b5d540310
commit
e143096140
11
README.rst
11
README.rst
@ -309,7 +309,7 @@ Then, you may download all pictures of all followees with
|
|||||||
|
|
||||||
.. code:: python
|
.. code:: python
|
||||||
|
|
||||||
for f in loader.get_followers(PROFILE):
|
for f in loader.get_followees(PROFILE):
|
||||||
loader.download_profile(f['username'])
|
loader.download_profile(f['username'])
|
||||||
|
|
||||||
You could also download your last 20 liked pics with
|
You could also download your last 20 liked pics with
|
||||||
@ -325,11 +325,14 @@ To download the last 20 pictures with hashtag #cat, do
|
|||||||
|
|
||||||
loader.download_hashtag('cat', max_count=20)
|
loader.download_hashtag('cat', max_count=20)
|
||||||
|
|
||||||
If logged in, Instaloader is also able to download user stories:
|
Generally, Instaloader provides methods to iterate over the Posts from
|
||||||
|
a certain source.
|
||||||
|
|
||||||
.. code:: python
|
.. code:: python
|
||||||
|
|
||||||
loader.download_stories()
|
for post in loader.get_hashtag_posts('cat'):
|
||||||
|
# post is an instance of instaloader.Post
|
||||||
|
self.download_post(post, target='#cat')
|
||||||
|
|
||||||
Each Instagram profile has its own unique ID which stays unmodified even
|
Each Instagram profile has its own unique ID which stays unmodified even
|
||||||
if a user changes his/her username. To get said ID, given the profile's
|
if a user changes his/her username. To get said ID, given the profile's
|
||||||
@ -345,7 +348,7 @@ get the current username of a profile, given this unique ID
|
|||||||
|
|
||||||
.. code:: python
|
.. code:: python
|
||||||
|
|
||||||
loader.get_username_by_id(followees[0]['id'])
|
loader.get_username_by_id(loader.get_followees()[0]['id'])
|
||||||
|
|
||||||
.. as-module-intro-end
|
.. as-module-intro-end
|
||||||
|
|
||||||
|
@ -32,6 +32,7 @@ sys.path.insert(0, os.path.abspath('..'))
|
|||||||
# ones.
|
# ones.
|
||||||
extensions = [
|
extensions = [
|
||||||
'sphinx.ext.autodoc',
|
'sphinx.ext.autodoc',
|
||||||
|
'sphinx_autodoc_typehints',
|
||||||
'sphinx.ext.githubpages',
|
'sphinx.ext.githubpages',
|
||||||
]
|
]
|
||||||
|
|
||||||
@ -129,7 +130,10 @@ html_theme = 'alabaster'
|
|||||||
# further. For a list of options available for each theme, see the
|
# further. For a list of options available for each theme, see the
|
||||||
# documentation.
|
# documentation.
|
||||||
#
|
#
|
||||||
# html_theme_options = {}
|
html_theme_options = {
|
||||||
|
'show_powered_by': False,
|
||||||
|
'sidebar_width': '290px',
|
||||||
|
'page_width': '935px' }
|
||||||
|
|
||||||
# Add any paths that contain custom themes here, relative to this directory.
|
# Add any paths that contain custom themes here, relative to this directory.
|
||||||
# html_theme_path = []
|
# html_theme_path = []
|
||||||
|
@ -4,3 +4,8 @@ Installation
|
|||||||
.. include:: ../README.rst
|
.. include:: ../README.rst
|
||||||
:start-after: installation-start
|
:start-after: installation-start
|
||||||
:end-before: installation-end
|
:end-before: installation-end
|
||||||
|
|
||||||
|
If you do not want to use pip, even though it is highly recommended,
|
||||||
|
and prefer installing Instaloader manually,
|
||||||
|
`Download the Source <https://github.com/Thammus/instaloader/releases>`__,
|
||||||
|
extract the Zip or Tarball and execute ``instaloader.py`` from there.
|
||||||
|
1
docs/requirements.txt
Normal file
1
docs/requirements.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
sphinx-autodoc-typehints
|
@ -1011,11 +1011,12 @@ class Instaloader:
|
|||||||
"""
|
"""
|
||||||
Download pictures from the user's feed.
|
Download pictures from the user's feed.
|
||||||
|
|
||||||
Example to download up to the 20 pics the user last liked:
|
Example to download up to the 20 pics the user last liked: ::
|
||||||
>>> loader = Instaloader()
|
|
||||||
>>> loader.load_session_from_file('USER')
|
loader = Instaloader()
|
||||||
>>> loader.download_feed_posts(max_count=20, fast_update=True,
|
loader.load_session_from_file('USER')
|
||||||
>>> filter_func=lambda post: post.viewer_has_liked)
|
loader.download_feed_posts(max_count=20, fast_update=True,
|
||||||
|
filter_func=lambda post: post.viewer_has_liked)
|
||||||
|
|
||||||
:param max_count: Maximum count of pictures to download
|
:param max_count: Maximum count of pictures to download
|
||||||
:param fast_update: If true, abort when first already-downloaded picture is encountered
|
:param fast_update: If true, abort when first already-downloaded picture is encountered
|
||||||
@ -1049,9 +1050,10 @@ class Instaloader:
|
|||||||
fast_update: bool = False) -> None:
|
fast_update: bool = False) -> None:
|
||||||
"""Download pictures of one hashtag.
|
"""Download pictures of one hashtag.
|
||||||
|
|
||||||
To download the last 30 pictures with hashtag #cat, do
|
To download the last 30 pictures with hashtag #cat, do ::
|
||||||
>>> loader = Instaloader()
|
|
||||||
>>> loader.download_hashtag('cat', max_count=30)
|
loader = Instaloader()
|
||||||
|
loader.download_hashtag('cat', max_count=30)
|
||||||
|
|
||||||
:param hashtag: Hashtag to download, without leading '#'
|
:param hashtag: Hashtag to download, without leading '#'
|
||||||
:param max_count: Maximum count of pictures to download
|
:param max_count: Maximum count of pictures to download
|
||||||
|
Loading…
Reference in New Issue
Block a user