ccslis

ccslis

create daily notices for all schools in /home/wcmckee/ccschol

Report back on all signins.

Live roll data.

Students and Staff Payroll on signinlca/usernames.

Create blog post on Nikola blog with student profile. Post profile contains student details and link to their profile blog.

Turn py file into ipynb. Seprate cells in py file with template code.

First creates blogs for every school. Creates post of each student on blog. Create blog of each student. Create blog post of every day they were enrolled at a school.

In [9]:
import os
import pandas
import arrow

walk folderr for all ipynb not in wcm.com posts folder.

Two lists 0 - .ipynb files not in wcm.com 1 - .ipynb files in wcm.com

In [10]:
arti = arrow.now()
In [11]:
arti
Out[11]:
<Arrow [2015-09-30T08:55:59.179386+13:00]>
In [23]:
opcomp = os.listdir('/home/wcmckee/github/')
In [ ]:
 
In [ ]:
 
In [24]:
opcomp
Out[24]:
['pydnz',
 'getsdrawndotcom',
 'signinlca',
 'lcacoffee',
 'wcmckee.com',
 'wcmckee-notebook',
 'pianobar',
 'wcmbbdotcom',
 'nikola-site',
 'jupyterhub_cookie_secret',
 'superblog',
 'pyshorteners',
 'wcm',
 'garrison-wow-track',
 'niketa',
 'icalendar',
 'devstack',
 'nikola',
 'config.txt',
 'pytm',
 'chriswarrick.com',
 'wcm.com',
 'control-pianobar',
 'ece-display',
 'cv',
 'hamiltoncomputerclub.org.nz',
 'jupyterhub.sqlite',
 'cs4hs',
 'wcmckee',
 'brobeurdotcom',
 'bacongamejam05',
 'pelican-themes',
 'gwt']
In [21]:
alccs = os.listdir('/home/wcmckee/ccschol/')
In [15]:
pandas.TimeSeries(arti)
Out[15]:
0    2015-09-30T08:55:59.179386+13:00
dtype: object
In [22]:
for alc in alccs:
    print(alc)
te-wharekura-o-maniapoto
ardmore
shotover-school
hobsonville-point-secondary-school
south-hornby
thorndon
leigh-school
st-josephs-upper-hutt
green-bay
oaklands-
hampden-street
rangiora-borough
pegasus-bay
te-pa-o-rakaihautu
paparoa-street
te-one
kaikohe-west
thorrington
grey-lynn
ohoka
westlake-girls-high-school
merrin
stonefields-school
sylvia-park-school
roydvale
marlborough-primary
ward
raphael-house
whau-valley
taipa-area-school-
pukekohe-intermediate
ashburton-intermediate
onewhero-area
rawhiti
horowhenua-college
our-lady-star-of-the-sea-sumner
taradale-intermediate
eastern-hutt
st-marys-catholic-tauranga
windwhistle
northcote-college
diamond-harbour
barton-rural
orewa-college
ebbett-park
shirley-intermediate
sumner
arrowtown
taupaki-school
yaldhurst-model
nelson-park
wellington-high-school
redwood-tawa
somerfield
marewa
albany-senior-high-school
middleton-grange-school
kaingaroa-chatham-islands
cheviot-area
okaihau-college
runanga
hutt-valley-high-school
our-lady-of-victoriea
burnside-high-school
hillpark
tkkm-o-te-atihaunui-a-paparangi
tawa-intermediate
auckland-girls-grammar-school
broadfield
westmere
kaikoura-suburban
whangaparaoa-college
our-lady-of-snows-methven
waikato-diocesan
warrington-school
banks-avenue
cobham-intermediate
st-patrick’s-bryndwr
hobsonville-point-primary-school
te-hihi
st-patrick’s-kaiapoi
springston-school
nayland-college
elmwood-normal
pakuranga-heights-school
sacred-heart-catholic
eskdale
In [ ]:
 
In [ ]:
 
In [ ]:
 
In [19]:
pver = pandas.version
In [20]:
str(pver)
Out[20]:
"<module 'pandas.version' from '/usr/lib/python3/dist-packages/pandas/version.py'>"
In [32]:
str(arti.date())
Out[32]:
'2015-09-28'
In [33]:
str(arti.time())
Out[33]:
'05:22:29.894485'
In [37]:
for alc in alccs:
    print(alc)
    oprsf = open('/home/wcmckee/ccschol/' + alc + '/posts/test.rst', 'w')
    oprsf.write('Hello ' + alc)
    oprsf.close()
    
    opmet = open('/home/wcmckee/ccschol/' + alc + '/posts/test.meta', 'w')
    
    opmet.write(alc + '\n' + alc + '\n' + str(arti.date()) + ' ' + str(arti.time()))
    opmet.close()
te-wharekura-o-maniapoto
ardmore
shotover-school
hobsonville-point-secondary-school
south-hornby
thorndon
leigh-school
st-josephs-upper-hutt
green-bay
oaklands-
hampden-street
rangiora-borough
pegasus-bay
te-pa-o-rakaihautu
paparoa-street
te-one
kaikohe-west
thorrington
grey-lynn
ohoka
westlake-girls-high-school
merrin
stonefields-school
sylvia-park-school
roydvale
marlborough-primary
ward
raphael-house
whau-valley
taipa-area-school-
pukekohe-intermediate
ashburton-intermediate
onewhero-area
rawhiti
horowhenua-college
our-lady-star-of-the-sea-sumner
taradale-intermediate
eastern-hutt
st-marys-catholic-tauranga
windwhistle
northcote-college
diamond-harbour
barton-rural
orewa-college
ebbett-park
shirley-intermediate
sumner
arrowtown
taupaki-school
yaldhurst-model
nelson-park
wellington-high-school
redwood-tawa
somerfield
marewa
albany-senior-high-school
middleton-grange-school
kaingaroa-chatham-islands
cheviot-area
okaihau-college
runanga
hutt-valley-high-school
our-lady-of-victoriea
burnside-high-school
hillpark
tkkm-o-te-atihaunui-a-paparangi
tawa-intermediate
auckland-girls-grammar-school
broadfield
westmere
kaikoura-suburban
whangaparaoa-college
our-lady-of-snows-methven
waikato-diocesan
warrington-school
banks-avenue
cobham-intermediate
st-patrick’s-bryndwr
hobsonville-point-primary-school
te-hihi
st-patrick’s-kaiapoi
springston-school
nayland-college
elmwood-normal
pakuranga-heights-school
sacred-heart-catholic
eskdale
In [38]:
for alc in alccs:
    print(alc)
    os.chdir('/home/wcmckee/ccschol/' + alc)
    os.system('nikola build')
    
te-wharekura-o-maniapoto
ardmore
shotover-school
hobsonville-point-secondary-school
south-hornby
thorndon
leigh-school
st-josephs-upper-hutt
green-bay
oaklands-
hampden-street
rangiora-borough
pegasus-bay
te-pa-o-rakaihautu
paparoa-street
te-one
kaikohe-west
thorrington
grey-lynn
ohoka
westlake-girls-high-school
merrin
stonefields-school
sylvia-park-school
roydvale
marlborough-primary
ward
raphael-house
whau-valley
taipa-area-school-
pukekohe-intermediate
ashburton-intermediate
onewhero-area
rawhiti
horowhenua-college
our-lady-star-of-the-sea-sumner
taradale-intermediate
eastern-hutt
st-marys-catholic-tauranga
windwhistle
northcote-college
diamond-harbour
barton-rural
orewa-college
ebbett-park
shirley-intermediate
sumner
arrowtown
taupaki-school
yaldhurst-model
nelson-park
wellington-high-school
redwood-tawa
somerfield
marewa
albany-senior-high-school
middleton-grange-school
kaingaroa-chatham-islands
cheviot-area
okaihau-college
runanga
hutt-valley-high-school
our-lady-of-victoriea
burnside-high-school
hillpark
tkkm-o-te-atihaunui-a-paparangi
tawa-intermediate
auckland-girls-grammar-school
broadfield
westmere
kaikoura-suburban
whangaparaoa-college
our-lady-of-snows-methven
waikato-diocesan
warrington-school
banks-avenue
cobham-intermediate
st-patrick’s-bryndwr
hobsonville-point-primary-school
te-hihi
st-patrick’s-kaiapoi
springston-school
nayland-college
elmwood-normal
pakuranga-heights-school
sacred-heart-catholic
eskdale
In [ ]:
 
In [ ]:
 
In [ ]:
 
In [ ]:
 

Comments

Comments powered by Disqus