Skip to content

Commit 92d47ac

Browse files
committed
[build] Fixing Rakefile to bump nightly for Python
1 parent 4241425 commit 92d47ac

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

Rakefile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -621,10 +621,11 @@ namespace :py do
621621

622622
desc 'Update Python version'
623623
task :version, [:version] do |_task, arguments|
624+
bump_nightly = arguments[:version] === 'nightly'
624625
old_version = python_version
625626
new_version = nil
626-
if arguments[:version] === 'nightly' && old_version.include?('nightly')
627-
new_version = old_version + ".#{Time.now.strftime("%Y%m%d")}"
627+
if bump_nightly && old_version.include?('nightly')
628+
new_version = old_version.gsub('nightly', "#{Time.now.strftime("%Y%m%d")}")
628629
else
629630
new_version = updated_version(old_version, arguments[:version])
630631
new_version += '.nightly' unless old_version.include?('nightly')
@@ -645,7 +646,7 @@ namespace :py do
645646
text = File.read('py/docs/source/conf.py').gsub(old_short_version, new_short_version)
646647
File.open('py/docs/source/conf.py', "w") { |f| f.puts text }
647648

648-
Rake::Task['py:changelog'].invoke unless new_version.include?('nightly')
649+
Rake::Task['py:changelog'].invoke unless new_version.include?('nightly') || bump_nightly
649650
end
650651

651652
desc 'Update Python Syntax'

py/CHANGES

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
Selenium 4.17.2
2-
3-
41
Selenium 4.17.2
52
* [py] Correct typing_extension dependency for wheel generation
63

0 commit comments

Comments
 (0)