Skip to content

Commit

Permalink
[mesonpy] add _version file
Browse files Browse the repository at this point in the history
  • Loading branch information
ogiorgis committed Dec 21, 2023
1 parent ee6030c commit 2de58d4
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions fluidsim/_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import importlib_metadata

__version__ = importlib_metadata.version(__package__)


__all__ = ["__version__", "get_local_version", "__about__"]

try:
from pyfiglet import figlet_format

__about__ = figlet_format("fluidsim", font="big")
except ImportError:
__about__ = r"""
__ _ _ _ _
/ _| | (_) | | (_)
| |_| |_ _ _ __| |___ _ _ __ ___
| _| | | | | |/ _` / __| | '_ ` _ \
| | | | |_| | | (_| \__ \ | | | | | |
|_| |_|\__,_|_|\__,_|___/_|_| |_| |_|
"""

__about__ = __about__.rstrip() + f"\n\n{28 * ' '} v. {__version__}\n"

_loc_version = None


def get_local_version():
"""Get a long "local" version."""

return __version__

0 comments on commit 2de58d4

Please sign in to comment.