Skip to content

Commit c2ded44

Browse files
Isaac DickinsonIsaac Dickinson
authored andcommitted
Merge pull request #57 from bool-dev/master
Fixed documentation error introduced in pr #56.
2 parents 9d6ff57 + bc94843 commit c2ded44

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

docs/index.rst

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ Flask-S3 know about your :class:`flask.Flask` application object.
7777
from flask_s3 import FlaskS3
7878
7979
app = Flask(__name__)
80-
app.config['S3_BUCKET_NAME'] = 'mybucketname'
80+
app.config['FLASKS3_BUCKET_NAME'] = 'mybucketname'
8181
s3 = FlaskS3(app)
8282
8383
In many cases, however, one cannot expect a Flask instance to be ready
@@ -143,11 +143,11 @@ Setting Custom HTTP Headers
143143
~~~~~~~~~~~~~~~~~
144144

145145
To set custom HTTP headers on the files served from S3 specify what
146-
headers you want to use with the `S3_HEADERS` option.
146+
headers you want to use with the `FLASKS3_HEADERS` option.
147147

148148
.. code-block:: python
149149
150-
S3_HEADERS = {
150+
FLASKS3_HEADERS = {
151151
'Expires': 'Thu, 15 Apr 2010 20:00:00 GMT',
152152
'Cache-Control': 'max-age=86400',
153153
}
@@ -180,7 +180,7 @@ uploading assets to S3.
180180
`FLASKS3_CDN_DOMAIN` AWS makes it easy to attach CloudFront to an S3
181181
bucket. If you want to use this or another CDN,
182182
set the base domain here. This is distinct from the
183-
`S3_BUCKET_DOMAIN` since it will not include the
183+
`FLASKS3_BUCKET_DOMAIN` since it will not include the
184184
bucket name in the base url.
185185
`FLASKS3_BUCKET_NAME` The desired name for your Amazon S3 bucket. Note:
186186
the name will be visible in all your assets' URLs.
@@ -201,17 +201,16 @@ uploading assets to S3.
201201
`flask.url_for`.
202202
**Default:** `True`
203203
**Note**: if you run your application in `debug`_
204-
mode (and `USE_S3_DEBUG` is `False` - see next
205-
item), `USE_S3` will be changed to `False`. This
206-
allows the `USE_S3` config variable to be the
207-
definitive check as to whether `flask_s3.url_for`
204+
mode (and `FLASKS3_DEBUG` is `False` - see next
205+
item), `FLASKS3_ACTIVE` will be changed to `False`.
206+
This allows the `FLASKS3_ACTIVE` config variable to be the definitive check as to whether `flask_s3.url_for`
208207
is overriding `flask.url_for`.
209208
`FLASKS3_DEBUG` By default, Flask-S3 will be switched off when
210209
running your application in `debug`_ mode, so that
211210
your templates include static asset locations
212211
specified by `flask.url_for`. If you wish to enable
213212
Flask-S3 in debug mode, set this value to `True`.
214-
**Note**: if `USE_S3` is set to `False` then
213+
**Note**: if `FLASKS3_ACTIVE` is set to `False` then
215214
templates will always include asset locations
216215
specified by `flask.url_for`.
217216
`FLASKS3_HEADERS` Sets custom headers to be sent with each file to S3.
@@ -228,17 +227,17 @@ uploading assets to S3.
228227
`FLASKS3_ONLY_MODIFIED` Only upload files that have been modified since last
229228
upload to S3. SHA-1 file hashes are used to compute
230229
file changes. You can delete `.file-hashes` from
231-
your S3 bucket to force all files to upload again.ad.
230+
your S3 bucket to force all files to upload again.
232231
`FLASKS3_GZIP` Compress all assets using GZIP and set the
233232
corresponding Content-Type and Content-Encoding
234233
headers on the S3 files.
235234
`FLASKS3_GZIP_ONLY_EXTS` A list of file extensions that should be gzipped.
236-
`FLASKS3_GZIP` should be `True` for this to take effect.
235+
``FLASKS3_GZIP`` should be ``True`` for this to take effect.
237236
If mentioned and non-empty, then only files with the
238237
specified extensions are gzipped.
239238
Defaults to empty list, meaning all files will be
240239
gzipped.
241-
Eg:- `['.js', '.css']` will gzip only js and css files.
240+
Eg:- ``['.js', '.css']`` will gzip only js and css files.
242241
`FLASKS3_FORCE_MIMETYPE` Always set the Content-Type header on the S3 files
243242
irrespective of gzipping. Defaults to `False`.
244243
=========================== ===================================================

0 commit comments

Comments
 (0)