Skip to content

Commit

Permalink
Added a new "name" configuration option to customize a project name //
Browse files Browse the repository at this point in the history
…Resolve #4498
  • Loading branch information
ivankravets committed Jan 14, 2023
1 parent 2337dbd commit 42f1197
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
3 changes: 2 additions & 1 deletion HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,11 @@ PlatformIO Core 6
~~~~~~~~~~~~~~~~~~

* Added support for Python 3.11
* Added a new `name <https://docs.platformio.org/en/latest/projectconf/sections/platformio/options/generic/description.html>`__ configuration option to customize a project name (`pull #4498 <https://github.com/platformio/platformio-core/pull/4498>`_)
* Made assets (templates, ``99-platformio-udev.rules``) part of Python's module (`issue #4458 <https://github.com/platformio/platformio-core/issues/4458>`_)
* Updated `Clang-Tidy <https://docs.platformio.org/en/latest/plus/check-tools/clang-tidy.html>`__ check tool to v15.0.5 with new diagnostics and bugfixes
* Removed dependency on the "zeroconf" package and install it only when a user lists mDNS devices (issue with zeroconf's LGPL license)
* Show the real error message instead of "Can not remove temporary directory" when "platform.ini" is broken (`issue #4480 <https://github.com/platformio/platformio-core/issues/4480>`_)
* Show the real error message instead of "Can not remove temporary directory" when |PIOCONF| is broken (`issue #4480 <https://github.com/platformio/platformio-core/issues/4480>`_)

6.1.5 (2022-11-01)
~~~~~~~~~~~~~~~~~~
Expand Down
4 changes: 3 additions & 1 deletion platformio/project/integration/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,9 @@ def _load_tplvars(self):
tpl_vars = {
"config": self.config,
"systype": util.get_systype(),
"project_name": os.path.basename(self.project_dir),
"project_name": self.config.get(
"platformio", "name", os.path.basename(self.project_dir)
),
"project_dir": self.project_dir,
"original_env_name": self.original_env_name,
"env_name": self.env_name,
Expand Down
5 changes: 5 additions & 0 deletions platformio/project/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,11 @@ def get_default_core_dir():
#
# [platformio]
#
ConfigPlatformioOption(
group="generic",
name="name",
description="A project name",
),
ConfigPlatformioOption(
group="generic",
name="description",
Expand Down

0 comments on commit 42f1197

Please sign in to comment.