Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 18 lines (14 sloc) 0.635 kb
3b13261 @AArnott Feature complete version of Atom2Blogger.
authored
1 param ($username, $password, $uri)
2
3 function Get-Service($username, $password) {
4 [void][reflection.assembly]::LoadFile("$env:ProgramFiles\Google\Google Data API SDK\Redist\Google.GData.Client.dll")
5 $svc = new-object Google.GData.Client.Service("blogger","atom2blogger")
6 $svc.credentials = new-object net.networkcredential($username, $password)
7 $svc
8 }
9
10 function Get-AtomFeed($service, $uri, $numberToRetrieve=100) {
11 $query = New-Object Google.GData.Client.FeedQuery($uri)
12 $query.NumberToRetrieve = $numberToRetrieve
13 $service.Query($query)
14 }
15
16 $svc = Get-Service $username $password
17 $feed = Get-AtomFeed $svc $uri
Something went wrong with that request. Please try again.