I hereby claim:
- I am heim on github.
- I am heimunacast (https://keybase.io/heimunacast) on keybase.
- I have a public key ASAf7FlWC-Kv1C2tUlo71Eid8_ExC9QUzBtGSFMtQzaVfwo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
NoSQL RoadShow 2012
| define(["moment"], function(moment) { | |
| function PrognosisTimeKeeper(prognosisTime) { | |
| var initialPrognosisTime = function() { | |
| //this == Window | |
| var currentTime = moment(this.lastPrognosisTime, "DD.MM.YYYY HH:MM"); | |
| return currentTime.add("h", 4).format("YYYY-MM-DD HH\\0\\0"); | |
| }; | |
| var setNewPrognosisTime = function() { | |
| this.lastPrognosisTime = prognosisTime.get("lastPrognosisProductionTime"); | |
| }; |
| #!/bin/bash | |
| set -e | |
| function main() { | |
| git rev-list --reverse --since="6 months ago" HEAD | | |
| while read rev; do | |
| echo "`revision_time`, `line_count`" | |
| done | |
| } |
| say "Rim me up, before you go go. rapapapapapa bappbappbapp.......... BANG" |
| public void testSave() { | |
| Currency currency = new Currency(); | |
| _templateMock.expects(once()).method("merge").with(same(currency)); | |
| _currencyDAO.save(currency); | |
| } |
| import org.junit.Test | |
| import javax.sql.DataSource | |
| import org.apache.commons.dbcp.BasicDataSource | |
| import static junit.framework.Assert.assertNotNull | |
| import org.springframework.jdbc.core.simple.SimpleJdbcTemplate | |
| import org.springframework.jdbc.core.RowMapper | |
| import java.sql.ResultSet | |
| import org.joda.time.LocalDate |
| private void updateTerm() { | |
| if (_orderComponent.getOrder().getPrint().getEdition().getCalculationType() == Edition.COMPENSATION) { | |
| String[] props = { "price", "currency", "unit", "maxCount", "validUntil", "deadline", "recived", "permanent", "status" }; | |
| PropertyUtils.copyProperties(_orderComponent.getTerm(), _term, props); | |
| if (_term.getExternalInvoice() != null && !_term.getExternalInvoice().getAmountString().equals("")) { | |
| float amount = FloatUtil.stringToFloat(_term.getExternalInvoice().getAmountString()); | |
| _term.getExternalInvoice().setAmount(amount); | |
| _orderComponent.getTerm().setExternalInvoice(_term.getExternalInvoice()); | |
| } else { |
| require 'vagrant' | |
| task :hello do | |
| env = Vagrant::Environment.new | |
| raise "Must run `vagrant up`" if !env.primary_vm.created? | |
| raise "Must be running!" if !env.primary_vm.vm.running? | |
| env.primary_vm.ssh.execute do |ssh| | |
| ssh.exec!("echo 'Hello BuyPass' > hello.txt") | |
| end |