- Update version in
project.clj
lein deploy clojars
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; using Clojure 1.9 | |
(require '[clojure.pprint :as pprint]) | |
(defn xform-dep [[lib version & korks]] | |
(let [args (into {} (apply hash-map korks))] | |
[lib (merge {:mvn/version version} args)])) | |
(defn xform-deps | |
"deps.edn utility function by @theronic 2018-02-28 | |
Transforms a collection of project.clj :dependencies to deps.edn style |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns my-backend.core | |
(:gen-class) | |
(:require [compojure.core :as c] | |
[compojure.route :as route] | |
[ring.adapter.jetty :as jetty] | |
[ring.middleware.defaults :as ring-defaults] | |
[hiccup2.core :as h] | |
#_[muuntaja.core :as m] | |
[muuntaja.middleware :as muuntaja])) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns datomic-helpers | |
(:require [datomic.api :as d])) | |
;;; Expose Datomic vars here, for convenience | |
;;; Ring middleware | |
(defn wrap-datomic | |
"A Ring middleware that provides a request-consistent database connection and | |
value for the life of a request." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require '[clojure.spec.alpha :as s]) | |
[:h1 {} "0" 1 [:span]] | |
(s/def :hiccup/form | |
(s/or | |
:string string? | |
:number number? | |
:element :hiccup/element)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Datomic example code | |
(use '[datomic.api :only (db q) :as d]) | |
;; ?answer binds a scalar | |
(q '[:find ?answer :in ?answer] | |
42) | |
;; of course you can bind more than one of anything | |
(q '[:find ?last ?first :in ?last ?first] | |
"Doe" "John") |
I used to use NERD tree for quite a while, then switched to CtrlP for something a little more lightweight. My setup now includes zero file browser or tree view, and instead uses native Vim fuzzy search and auto-directory switching.
There is a super sweet feature in Vim whereby you can fuzzy find your files using **/*
, e.g.:
:vs **/*<partial file name><Tab>
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{:paths ["."] | |
:deps {clansi {:mvn/version "1.0.0"}}} |
From VAST 3.0 Spec (PDF)
Code | Description |
---|---|
100 | XML parsing error. |
101 | VAST schema validation error. |
102 | VAST version of response not supported. |
200 | Trafficking error. Video player received an Ad type that it was not expecting and/or cannot display. |
NewerOlder