Skip to content

Commit

Permalink
add ENDPOINT_URL environment option (#53)
Browse files Browse the repository at this point in the history
* add ENDPOINT_URL environment option

* fix dupe default

* update poetry dependencies
  • Loading branch information
smousa authored Mar 19, 2024
1 parent 16cd382 commit 5be04c7
Show file tree
Hide file tree
Showing 5 changed files with 383 additions and 314 deletions.
3 changes: 2 additions & 1 deletion parquet_tools/commands/csv.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
import sys
from argparse import ArgumentParser, Namespace
from typing import List, Optional
Expand Down Expand Up @@ -34,7 +35,7 @@ def configure_parser(paser: ArgumentParser) -> ArgumentParser:
paser.add_argument('--endpoint-url',
type=str,
required=False,
default=None,
default=os.environ.get('ENDPOINT_URL'),
help='A custom S3 endpoint URL')
paser.set_defaults(handler=_cli)
return paser
Expand Down
3 changes: 2 additions & 1 deletion parquet_tools/commands/inspect.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
import sys
from argparse import ArgumentParser, Namespace
from typing import List
Expand Down Expand Up @@ -32,7 +33,7 @@ def configure_parser(paser: ArgumentParser) -> ArgumentParser:
paser.add_argument('--endpoint-url',
type=str,
required=False,
default=None,
default=os.environ.get('ENDPOINT_URL'),
help='A custom S3 endpoint URL')

paser.set_defaults(handler=_cli)
Expand Down
3 changes: 2 additions & 1 deletion parquet_tools/commands/show.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
import sys
from argparse import ArgumentParser, Namespace
from logging import getLogger
Expand Down Expand Up @@ -49,7 +50,7 @@ def configure_parser(paser: ArgumentParser) -> ArgumentParser:
paser.add_argument('--endpoint-url',
type=str,
required=False,
default=None,
default=os.environ.get('ENDPOINT_URL'),
help='A custom S3 endpoint URL')

paser.set_defaults(handler=_cli)
Expand Down
Loading

0 comments on commit 5be04c7

Please sign in to comment.