Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add KAGGLE_KERNELS_PRIVATE environment variable #12

Merged
merged 8 commits into from
Jul 27, 2024
1 change: 1 addition & 0 deletions .github/workflows/doit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
workflow_dispatch:

env:
KAGGLE_KERNELS_PRIVATE: "no"
PYTHON_VERSION: "3.11"

permissions:
Expand Down
8 changes: 4 additions & 4 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,15 @@ def main(include_private=False, max_page_size=MAX_PAGE_SIZE, user=None, output_n
tmp_dir_prefix="kaggle_", tmp_dir=None):
parser = argparse.ArgumentParser(description="Download All Kaggle Kernels")
parser.add_argument("-o", "--output", type=validate_filename, default=output_name,
help="Name of the output zip file (default: kernels.zip)")
help=f"Name of the output zip file (default: {output_name})")
parser.add_argument("-p", "--include-private", action="store_true", default=include_private,
help="Include private kernels in the download (default: False)")
help=f"Include private kernels in the download (default: {include_private})")
parser.add_argument("-u", "--user", type=str, default=user,
help="Username of the Kaggle user to search kernels for (default: current user)")
parser.add_argument("-s", "--max-page-size", type=validate_positive_int, default=max_page_size,
help="Maximum number of kernels to download per page (default: 100)")
help=f"Maximum number of kernels to download per page (default: {max_page_size})")
parser.add_argument("-t", "--tmp-dir", type=str, default=tmp_dir,
help="Path to the temporary directory (default: None)")
help=f"Path to the temporary directory (default: {tmp_dir})")

args = parser.parse_args()

Expand Down
Loading