mirror of
https://github.com/jupyter/docker-stacks.git
synced 2025-10-19 07:52:56 +00:00
Better tagging directory structure (#2228)
This commit is contained in:
13
tagging/taggers/date.py
Normal file
13
tagging/taggers/date.py
Normal file
@@ -0,0 +1,13 @@
|
||||
# Copyright (c) Jupyter Development Team.
|
||||
# Distributed under the terms of the Modified BSD License.
|
||||
import datetime
|
||||
|
||||
from docker.models.containers import Container
|
||||
|
||||
from tagging.taggers.tagger_interface import TaggerInterface
|
||||
|
||||
|
||||
class DateTagger(TaggerInterface):
|
||||
@staticmethod
|
||||
def tag_value(container: Container) -> str:
|
||||
return datetime.datetime.now(datetime.UTC).strftime("%Y-%m-%d")
|
Reference in New Issue
Block a user