<commit_before># S3 Download by date range [![Gem Version](https://badge.fury.io/rb/s3_download_by_date.svg)](http://badge.fury.io/rb/s3_download_by_date)

S3 Download files by modifed date (Range)

## Installation

    $ gem install s3-download-by-date


## Configuration
add to your ~/.bash_profile (~/.zprofile if using ZSH)

```bash
export REGION='eu-west-1' (default to us-east-1)
export AWS_ACCESS_KEY="YOUR AWS KEY ID"
export AWS_SECRET_KEY="YOUR AWS SECRET KEY"

```

## Usage

````bash
s3download range --bucket=s3-bucket-name --prefix=folder_or_file_prefix --from='yesterday at noon' --to='today at noon' --save-to=~/Downloads
````

s3download uses [Chronic](https://github.com/mojombo/chronic) library to set the --from and --to


Or download by timezone

````bash
s3download range --timezone='Eastern Time (US & Canada)'  ' --bucket=s3-bucket-name --prefix=folder_or_file_prefix --from='yesterday at noon' --to='today at noon' --save-to=~/Downloads 
````

**Getting a list of timezones strings:**

 ````bash
 s3download list_timezones 
 ````

 ````javascript
  {
  "International Date Line West": "Pacific/Midway",
  "Midway Island": "Pacific/Midway",
  "American Samoa": "Pacific/Pago_Pago",
  "Hawaii": "Pacific/Honolulu",
  "Alaska": "America/Juneau",
  "Pacific Time (US & Canada)": "America/Los_Angeles"
  .
  .
  .
  }<commit_msg>fix readme<commit_after># S3 Download by date range [![Gem Version](https://badge.fury.io/rb/s3_download_by_date.svg)](http://badge.fury.io/rb/s3_download_by_date)

S3 Download files by modifed date (Range)

## Installation

    $ gem install s3_download_by_date

## Configuration
add to your ~/.bash_profile (~/.zprofile if using ZSH)

```bash
export REGION='eu-west-1' (default to us-east-1)
export AWS_ACCESS_KEY="YOUR AWS KEY ID"
export AWS_SECRET_KEY="YOUR AWS SECRET KEY"

```

## Usage

````bash
s3download  --bucket=s3-bucket-name \
            --prefix=folder or file prefix on S3 \
            --from='yesterday at noon' \ 
            --to='today at noon'  \
            --save-to=~/Downloads
````

s3download uses [Chronic](https://github.com/mojombo/chronic) library to set the --from and --to


Or download by timezone

````bash
s3download --timezone='Eastern Time (US & Canada)' \
           --bucket=s3-bucket-name \
           --prefix=folder_or_file_prefix \
           --from='yesterday at noon' \ 
           --to='today at noon' \
           --save-to=~/Downloads 
````

**Getting a list of timezones strings:**

 ````bash
 s3download list_timezones 
 ````

 ````javascript
  {
  "International Date Line West": "Pacific/Midway",
  "Midway Island": "Pacific/Midway",
  "American Samoa": "Pacific/Pago_Pago",
  "Hawaii": "Pacific/Honolulu",
  "Alaska": "America/Juneau",
  "Pacific Time (US & Canada)": "America/Los_Angeles"
  .
  .
  .
  }
{'fraction_non_alphanumeric': 0.1599002849002849, 'fraction_numerical': 0.009615384615384616, 'mean_word_length': 3.458730158730159, 'pattern_counts': {'":': 12, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 24, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6752761', 'n_tokens_mistral': 1077, 'n_tokens_neox': 988, 'n_words': 238}