diff options
author | Junghyun Kim <jh0822.kim@samsung.com> | 2016-08-23 19:30:57 +0900 |
---|---|---|
committer | Junghyun Kim <jh0822.kim@samsung.com> | 2016-08-23 19:30:57 +0900 |
commit | 1868d5482270bb459b20d58a4749da4525064256 (patch) | |
tree | 7c0c5a594e09572fde4d097e2571d3a4a6856cbc | |
parent | c5daa3aaf170968d9e8d436998a0a13dfd7f0c15 (diff) | |
download | pattern-tools-tizen.tar.gz pattern-tools-tizen.tar.bz2 pattern-tools-tizen.zip |
Sort file names using sorted()HEADtizen_9.0_m2_releasetizen_8.0_m2_releasetizen_7.0_m2_releasetizen_6.5.m2_releasetizen_6.0.m2_releasetizen_5.5.m2_releasetizen_4.0.m2_releasetizen_4.0.m1_releasetizen_4.0.IoT.p2_releasetizen_4.0.IoT.p1_releasesubmit/tizen_unified/20170308.100415submit/tizen_6.5/20211028.163601submit/tizen_6.0_hotfix/20201103.115103submit/tizen_6.0_hotfix/20201102.192903submit/tizen_6.0/20201029.205503submit/tizen_5.5_wearable_hotfix/20201026.184308submit/tizen_5.5_mobile_hotfix/20201026.185108submit/tizen_5.5/20191031.000008submit/tizen_5.0/20181101.000007submit/tizen_4.0/20170828.100007submit/tizen_4.0/20170811.094300submit/tizen_3.0_wearable/20161015.000005submit/tizen_3.0_tv/20161015.000004submit/tizen_3.0_mobile/20161015.000005submit/tizen_3.0_ivi/20161010.000005submit/tizen_3.0_common/20161104.104000submit/tizen_3.0.m2/20170104.093754submit/tizen/20160921.004331submit/tizen/20160913.071022submit/tizen/20160831.230944accepted/tizen/wearable/20160921.232910accepted/tizen/unified/20170309.040157accepted/tizen/tv/20160921.232923accepted/tizen/mobile/20160921.232916accepted/tizen/ivi/20160921.232930accepted/tizen/common/20160913.170441accepted/tizen/common/20160901.143250accepted/tizen/9.0/unified/20241030.232925accepted/tizen/8.0/unified/20231005.095328accepted/tizen/7.0/unified/hotfix/20221116.111233accepted/tizen/7.0/unified/20221110.061032accepted/tizen/6.5/unified/20211028.225043accepted/tizen/6.0/unified/hotfix/20201102.232108accepted/tizen/6.0/unified/20201030.112021accepted/tizen/5.5/unified/wearable/hotfix/20201027.104544accepted/tizen/5.5/unified/mobile/hotfix/20201027.072421accepted/tizen/5.5/unified/20191031.013026accepted/tizen/5.0/unified/20181102.030345accepted/tizen/4.0/unified/20170828.221718accepted/tizen/4.0/unified/20170816.011437accepted/tizen/3.0/wearable/20161015.083941accepted/tizen/3.0/tv/20161016.005521accepted/tizen/3.0/mobile/20161015.033911accepted/tizen/3.0/ivi/20161011.055438accepted/tizen/3.0/common/20161114.111428accepted/tizen/3.0.m2/wearable/20170105.025338accepted/tizen/3.0.m2/tv/20170105.025241accepted/tizen/3.0.m2/mobile/20170105.025131tizen_9.0tizen_8.0tizen_7.0_hotfixtizen_7.0tizen_6.5tizen_6.0_hotfixtizen_6.0tizen_5.5_wearable_hotfixtizen_5.5_tvtizen_5.5_mobile_hotfixtizen_5.5tizen_5.0tizen_4.0_tvtizen_4.0tizen_3.0_tvtizen_3.0.m2tizen_3.0tizenaccepted/tizen_wearableaccepted/tizen_unifiedaccepted/tizen_tvaccepted/tizen_mobileaccepted/tizen_iviaccepted/tizen_commonaccepted/tizen_9.0_unifiedaccepted/tizen_8.0_unifiedaccepted/tizen_7.0_unified_hotfixaccepted/tizen_7.0_unifiedaccepted/tizen_6.5_unifiedaccepted/tizen_6.0_unified_hotfixaccepted/tizen_6.0_unifiedaccepted/tizen_5.5_unified_wearable_hotfixaccepted/tizen_5.5_unified_mobile_hotfixaccepted/tizen_5.5_unifiedaccepted/tizen_5.0_unifiedaccepted/tizen_4.0_unifiedaccepted/tizen_3.0_wearableaccepted/tizen_3.0_tvaccepted/tizen_3.0_mobileaccepted/tizen_3.0_iviaccepted/tizen_3.0_commonaccepted/tizen_3.0.m2_wearableaccepted/tizen_3.0.m2_tvaccepted/tizen_3.0.m2_mobile
- PROBLEM
python's os.listdir() returns a list of files without sorting.
In this case, the list can be different across machines.
As a result, OBS can recognize build results are different everytime
even though the source is unchanged.
- SOLUTION
Use sorted(os.listdir()) instead of os.listdir().
Change-Id: Idf3ba1e51fb790269dafb651347ff84dbda89a10
Signed-off-by: Junghyun Kim <jh0822.kim@samsung.com>
-rwxr-xr-x | scripts/merge-patterns.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/merge-patterns.py b/scripts/merge-patterns.py index f6b9068..d499404 100755 --- a/scripts/merge-patterns.py +++ b/scripts/merge-patterns.py @@ -18,7 +18,7 @@ def create_patterns(arch='i586', split=False, patterns_dir='patterns', output=". NSMAP = {None : pattern_ns, "rpm": rpm_ns} count = 0 - for f in os.listdir(patterns_dir): + for f in sorted(os.listdir(patterns_dir)): if not f.endswith('.yaml'): continue count = count + 1 |