Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Adjust for strftime() handling %Y inconsistantly
On Debian systems, datetime.strftime("%Y") will produce less than a 4-digit year if the value is < 1000. On OS X and Windows sytems, it will pad on the left with zeros to create a 4-digit year when the value is < 1000. I changed the code to detect whether padding was applied and supply the correct padding if it was missing. Also added recipe for a Docker container that could be used for Ubuntu testing and development. Bump version to 1.1.2
- Loading branch information
Dave Hein
committed
Jun 9, 2016
1 parent
f821a73
commit 09a600f
Showing
11 changed files
with
129 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
# Using a base Ubuntu 14.04 that has the latest updates already | ||
# | ||
# Base images can be found here: https://hub.docker.com/_/ubuntu/ | ||
# Ubuntu 14.04 LTS (Trusty Tahr) is supported through 2019. | ||
# Ubuntu 16.04 LTS (Xenial Xerus) has just been released and probably should | ||
# not be used yet (because dependent software may need to be updated and | ||
# made compatible). | ||
# | ||
FROM ubuntu:14.04.4 | ||
MAINTAINER Dave Hein <dhein@acm.org> | ||
|
||
# Setting this environment variable prevents errors during package installs | ||
# that look like: | ||
# | ||
# debconf: unable to initialize frontend: Dialog | ||
# debconf: (TERM is not set, so the dialog frontend is not usable.) | ||
# debconf: falling back to frontend: Readline | ||
# | ||
# As per: http://stackoverflow.com/a/35976127/1392864 | ||
# | ||
ARG DEBIAN_FRONTEND=noninteractive | ||
|
||
# Update apt package info and upgrade installed packages (base image | ||
# has some packages installed) | ||
# | ||
# Install some basic package fetching tools | ||
# | ||
ENV FETCH_REFRESHED_AT 2016-06-08T05:25-0500 | ||
RUN apt-get update && apt-get -y upgrade \ | ||
apt-get install -yqq software-properties-common python-software-properties && \ | ||
apt-get -yqq install wget | ||
|
||
# Install Python 3.5 | ||
# | ||
ENV PYTHON35_REFRESHED_AT 2016-06-08T05:25-0500 | ||
RUN add-apt-repository ppa:fkrull/deadsnakes && \ | ||
apt-get update | ||
RUN apt-get install -yqq python3.5 | ||
RUN apt-get install -yqq python3.5-dev | ||
RUN apt-get install -yqq libncurses5-dev | ||
RUN apt-get install -yqq python3.5-venv | ||
|
||
# Install pip & setuptools | ||
# | ||
ENV PIP3_REFRESHED_AT 2016-06-08T05:47-0500 | ||
RUN wget https://bootstrap.pypa.io/get-pip.py | ||
RUN python3 get-pip.py | ||
RUN pip3 install setuptools --upgrade | ||
|
||
# Install git | ||
# | ||
ENV GIT_REFRESHED_AT 2016-06-08T05:47-0500 | ||
RUN apt-get install -yqq git-core | ||
|
||
# Install gcc | ||
# | ||
ENV GCC_REFRESHED_AT 2016-06-08T05:47-0500 | ||
RUN apt-get install -yqq \ | ||
autoconf \ | ||
automake \ | ||
g++ \ | ||
gcc \ | ||
libffi-dev \ | ||
libssl-dev \ | ||
make \ | ||
patch | ||
|
||
# Local stuff | ||
ENV LOCALSTUFF_REFRESHED_AT 2016-06-08T06:07-0500 | ||
COPY establish-dev.sh /root/trash/ | ||
WORKDIR /root/trash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#! /bin/bash | ||
# | ||
# Create the image ... for the python35 dev environment | ||
# | ||
docker build -t datihein/devauthenticator:python35 . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#! /bin/bash | ||
# | ||
git clone https://github.com/JeNeSuisPasDave/authenticator | ||
cd authenticator | ||
python3.5 -m venv --clear --copies venv35 | ||
. venv35/bin/activate | ||
pip install --quiet --upgrade pip | ||
pip install --quiet --upgrade setuptools | ||
./dev/venv/provision-venv.sh | ||
deactivate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#! /bin/bash | ||
# | ||
|
||
# Start the python35 dev container | ||
# | ||
docker run --rm -t -i \ | ||
datihein/devauthenticator:python35 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#! /bin/bash | ||
# | ||
PYTHONPATH="$(pwd)/src" python -m unittest \ | ||
tests.test_CLI.CoreCLITests.test_list_with_three_configs_verbose | ||
tests.test_ClientData.CoreClientDataTests.test_string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,4 +40,4 @@ | |
|
||
__author__ = "Dave Hein <dhein@acm.org>" | ||
__license__ = "MIT" | ||
__version__ = "1.1.1" | ||
__version__ = "1.1.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters