README.md in ba_upload-0.1.0 vs README.md in ba_upload-0.2.0

- old
+ new

@@ -1,7 +1,9 @@ # Bundesagentur fuer Arbeit upload +[![Gem Version](https://badge.fury.io/rb/ba_upload.svg)](https://badge.fury.io/rb/ba_upload) + This is a Ruby Gem that aids to simplify interaction with the API of the Arbeitsagentur of Germany. Since early 2016 Arbeitsagentur switched to a HTTPS client certificate (hrbaxml.arbeitsagentur.de) instead their beloved FTP upload tool. The OpenSSL library helps to convert that cert to a format Mechanize/curl can understand. ## Installation @@ -53,9 +55,21 @@ ``` Save to a file and just run it with the xml file as argument +### Downloading "misc" files + +BA provides a often updated Position description databae ("VAM" Berufe). The Gem can help to download it: + +``` +connection.misc.each do |link| + target = "vendor/ba/#{link.href}" + next if File.exist?(target) + response = link.click + File.open(target, "wb+") { |f| f.write(response.body) } +end +``` ## License The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).