Skip to content

Commit

Permalink
Merge pull request #47 from /issues/46-Rake_task_for_projects_from_se…
Browse files Browse the repository at this point in the history
…cond_python_path

Rake task for projects from second python path
  • Loading branch information
ArayB authored Apr 12, 2022
2 parents c37fedd + 51c16d2 commit 26cd52a
Show file tree
Hide file tree
Showing 251 changed files with 28,318 additions and 0 deletions.
142 changes: 142 additions & 0 deletions lib/tasks/project_components/charting_champions_example/carbon.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
Albania,4342.011,1.511
Algeria,130493.653,3.158
Angola,18021.394,0.605
Argentina,183375.203,4.142
Armenia,5165.593,1.763
Australia,384583.857,15.632
Austria,64872.394,7.376
Azerbaijan,30805.851,3.124
Bahrain,29813.834,19.969
Bangladesh,78270.17,0.475
Belarus,54070.453,5.687
Belgium,90368.188,7.963
Benin,6763.074,0.605
Bolivia (Plurin. State of),21899.18,1.981
Bosnia and Herzegovina,22327.978,6.367
Botswana,7717.409,3.367
Brazil,427632.717,2.043
Brunei Darussalam,6710.178,15.641
Bulgaria,42819.932,6.051
Côte d’Ivoire,10234.205,0.421
Cambodia,10762.923,0.672
Cameroon,6152.919,0.256
Canada,547798.641,14.992
Chile,86087.14,4.648
China,9257933.9,6.678
Colombia,75291.911,1.535
Congo,2847.335,0.541
Costa Rica,7584.411,1.546
Croatia,16193.172,3.925
Cuba,26215.665,2.283
Curaçao,3748.132,23.28
Cyprus,6367.874,7.448
Czechia,101682.752,9.602
Dem. People's Rep. Korea,19579.698,0.768
Dem. Rep. of the Congo,2201.742,0.027
Denmark,31263.57,5.421
Dominican Republic,21430.38,1.99
Ecuador,34299.317,2.063
Egypt,209219.059,2.145
El Salvador,5735.668,0.899
Eritrea,632.105,0.125
Estonia,15972.029,12.137
Ethiopia,13059.815,0.124
Finland,42598.175,7.734
France,306123.541,4.565
Gabon,3367.911,1.663
Georgia,8720.3,2.346
Germany,718794.085,8.696
Ghana,13779.635,0.478
Gibraltar,703.9,20.703
Greece,63213.31,5.878
Guatemala,15703.161,0.928
Haiti,3293.125,0.3
Honduras,9426.74,1.017
Hong Kong,44034.675,5.957
Hungary,45783.636,4.678
Iceland,2173.307,6.336
India,2161567.072,1.614
Indonesia,496406.275,1.88
Iran (Islamic Republic of),567123.294,6.987
Iraq,139877.659,3.655
Ireland,35720.302,7.439
Israel,63766.189,7.322
Italy,321481.224,5.31
Jamaica,6971.666,2.412
Japan,1132435.4,8.938
Jordan,25550.14,2.633
Kazakhstan,255767.646,14.179
Kenya,16264.973,0.327
Kosovo,8168.55,4.461
Kuwait,89420.615,21.615
Kyrgyzstan,8909.263,1.437
Latvia,6679.644,3.441
Lebanon,26931.044,4.428
Libya,41528.35,6.514
Lithuania,10811.096,3.831
Luxembourg,8631.187,14.458
Malaysia,211046.967,6.674
Malta,1516.276,3.261
Mauritius,4182.138,3.306
Mexico,445991.937,3.615
Mongolia,19276,6.267
Montenegro,2206.233,3.547
Morocco,58149.86,1.627
Mozambique,7624.932,0.257
Myanmar,30404.919,0.57
Namibia,4037.15,1.593
Nepal,10113.953,0.345
Netherlands,155574.278,9.081
New Zealand,32241.597,6.673
Nicaragua,5106.281,0.821
Niger,2048.704,0.095
Nigeria,85988.513,0.45
North Macedonia,7440.699,3.572
Norway,34760.858,6.587
Oman,65498.56,14.128
Pakistan,183447.068,0.931
Panama,9612.198,2.345
Paraguay,7654.689,1.124
Peru,49693.643,1.545
Philippines,126487.694,1.206
Poland,305841.991,7.96
Portugal,50757.815,4.928
Qatar,80116.551,30.359
Republic of Korea,600034.367,11.663
Republic of Moldova,7526.673,2.12
Romania,70788.76,3.614
Russian Federation,1536878.825,10.636
Saudi Arabia,532181.611,16.157
Senegal,8311.532,0.524
Serbia,46129.569,6.569
Singapore,47407.144,8.447
Slovakia,32212.012,5.924
Slovenia,13410.666,6.491
South Africa,421682.392,7.435
South Sudan,1549.031,0.123
Spain,253423.277,5.446
Sri Lanka,23103.271,1.077
Sudan,18777.895,0.463
Suriname,1928.134,3.425
Sweden,37643.785,3.743
Switzerland,37135.572,4.394
Syrian Arab Republic,23031.045,1.261
Tajikistan,5843.657,0.655
Thailand,244254.785,3.538
Togo,2082.434,0.267
Trinidad and Tobago,18007.573,13.154
Tunisia,26156.972,2.268
Turkey,378631.09,4.714
Turkmenistan,68998.881,11.983
Ukraine,171300.035,3.821
United Arab Emirates,196510.174,20.905
United Kingdom,358731.281,5.432
United Rep. of Tanzania,10131.79,0.177
United States of America,4761301.727,14.606
Uruguay,5872.957,1.699
Uzbekistan,81156.397,2.506
Venezuela (Boliv. Rep. of),113717.543,3.556
Viet Nam,191243.601,2.002
Yemen,8919.998,0.316
Zambia,6007.872,0.351
Zimbabwe,9714.938,0.588
22 changes: 22 additions & 0 deletions lib/tasks/project_components/charting_champions_example/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/python3
from pygal import Bar

# Create a chart
chart = Bar(title='Olympic medals')

# Add data to the chart
with open('medals.csv') as f:
data = f.read()
lines = data.splitlines()
#print(lines)

for line in lines:
tally = line.split(',')
#print(tally)

team = tally[0]
medals = tally[1]
chart.add(team, int(medals)) # Make medals a number

# Display the chart
chart.render()
23 changes: 23 additions & 0 deletions lib/tasks/project_components/charting_champions_example/mcu.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
Iron Man,126,585366247
The Incredible Hulk,112,264770996
Iron Man 2,124,623933331
Thor,115,449326618
Captain America: The First Avenger,124,370569774
The Avengers,143,1518812988
Iron Man 3,130,1214811252
Thor: The Dark World,112,644783140
Captain America: The Winter Soldier,136,714421503
Guardians of the Galaxy,121,772776600
Avengers: Age of Ultron,141,1402805868
Ant-Man,117,519311965
Captain America: Civil War,147,1153296293
Doctor Strange,115,677718395
Guardians of the Galaxy Vol. 2,136,863756051
Spider-Man: Homecoming,133,880166924
Thor: Ragnarok,130,853977126
Black Panther,134,1346913161
Avengers: Infinity War,149,2048359754
Ant-Man and the Wasp,118,622674139
Captain Marvel,123,1128274794
Avengers: Endgame,181,2797501328
Spider-Man: Far From Home,129,1131927996
138 changes: 138 additions & 0 deletions lib/tasks/project_components/charting_champions_example/medals.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
United States,2399
Russia,1413
Great Britain,1304
France,780
Germany,671
Italy,549
Sweden,483
Hungary,476
China,473
Australia,468
Japan,398
Finland,302
Romania,301
Canada,279
Poland,271
Netherlands,266
South Korea,243
Bulgaria,214
Cuba,209
Switzerland,185
Denmark,179
Norway,148
Czechoslovakia,143
Belgium,142
Spain,131
Ukraine,115
Greece,111
Brazil,108
New Zealand,99
Austria,86
Kenya,86
Turkey,86
Yugoslavia,83
South Africa,76
Belarus,75
Argentina,70
Jamaica,67
Mexico,62
Iran,60
Kazakhstan,52
North Korea,47
Ethiopia,45
Czech Republic,44
Estonia,33
Ireland,29
Indonesia,27
Azerbaijan,26
Egypt,26
India,26
Georgia,25
Mongolia,24
Slovakia,24
Thailand,24
Croatia,23
Nigeria,23
Portugal,23
Morocco,22
Lithuania,21
Uzbekistan,20
Colombia,19
Latvia,19
Slovenia,19
Chinese Taipei,19
Trinidad and Tobago,18
Algeria,15
Chile,13
Armenia,12
Australasia,12
Bahamas,12
Venezuela,12
Pakistan,10
Tunisia,10
Uruguay,10
Philippines,9
Serbia and Montenegro,9
Puerto Rico,8
Zimbabwe,8
Israel,7
Moldova,7
Serbia,7
Uganda,7
Dominican Republic,6
Malaysia,6
Cameroon,5
Bohemia,4
Costa Rica,4
Ghana,4
Iceland,4
Lebanon,4
Namibia,4
Peru,4
Qatar,4
Singapore,4
Hong Kong,3
Kyrgyzstan,3
Panama,3
Saudi Arabia,3
Syria,3
Tajikistan,3
Afghanistan,2
British West Indies,2
Ecuador,2
Haiti,2
Kuwait,2
Luxembourg,2
Mozambique,2
Sri Lanka,2
Suriname,2
Tanzania,2
Vietnam,2
Zambia,2
Bahrain,1
Barbados,1
Bermuda,1
Botswana,1
Burundi,1
Ivory Coast,1
Cyprus,1
Djibouti,1
Eritrea,1
Gabon,1
Grenada,1
Guatemala,1
Guyana,1
Iraq,1
Macedonia,1
Mauritius,1
Montenegro,1
Netherlands Antilles,1
Niger,1
Paraguay,1
Senegal,1
Sudan,1
Togo,1
Tonga,1
United Arab Emirates,1
Virgin Islands,1
Liechtenstein,0
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
NAME: "Charting Champions"
IDENTIFIER: "charting-champions-example"
COMPONENTS:
- name: "main"
extension: "py"
location: "main.py"
index: 0
default: true
- name: "medals"
extension: "csv"
location: "medals.csv"
index: 1
default: false
- name: "carbon"
extension: "csv"
location: "carbon.csv"
index: 2
default: false
- name: "mcu"
extension: "csv"
location: "mcu.csv"
index: 3
default: false
10 changes: 10 additions & 0 deletions lib/tasks/project_components/charting_champions_starter/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/python3
from pygal import Bar

# Create a chart


# Add data to the chart


# Display the chart
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
NAME: "Charting Champions"
IDENTIFIER: "charting-champions-starter"
COMPONENTS:
- name: "main"
extension: "py"
location: "main.py"
index: 0
default: true
Loading

0 comments on commit 26cd52a

Please sign in to comment.