Skip to content
Snippets Groups Projects
Commit 6feaa246 authored by Cam Saul's avatar Cam Saul
Browse files

remove `lein migration-summary` task since it no longer works

parent f7a8dbab
No related branches found
No related tags found
No related merge requests found
......@@ -78,12 +78,6 @@ You can update the GitHub pages documentation using
You should be on the `master` branch without any uncommited local changes before doing so. Also, make sure you've fetched the branch `gh-pages` and can push it back to `origin`.
## Migration Summary
lein migration-summary
Will give you a list of all tables + fields in the Metabase DB.
## Bootstrapping (for Development)
To quickly get your dev environment set up, use the `bootstrap` function to create a new User and Organization.
......@@ -143,7 +137,7 @@ Once's this repo is made public, this Clojars badge will work and show the statu
In general, we like to have an open issue for every pull request as a place to discuss the nature of any bug or proposed improvement. Each pull request should address a single issue, and contain both the fix as well as a description of how the pull request and tests that validate that the PR fixes the issue in question.
For significant feature additions, it is expected that discussion will have taken place in the attached issue. Any feature that requires a major decision to be reached will need to have an explicit design document written. The goals of this document are to make explicit the assumptions, constraints and tradeoffs any given feature implementation will contain. The point is not to generate documentation but to allow discussion to reference a specific proposed design and to allow others to consider the implications of a given design.
For significant feature additions, it is expected that discussion will have taken place in the attached issue. Any feature that requires a major decision to be reached will need to have an explicit design document written. The goals of this document are to make explicit the assumptions, constraints and tradeoffs any given feature implementation will contain. The point is not to generate documentation but to allow discussion to reference a specific proposed design and to allow others to consider the implications of a given design.
We don't like getting sued, so for every commit we require a Linux Kernel style developer certificate. If you agree to the below terms (from http://developercertificate.org/)
......
(ns leiningen.migration-summary
(:require [leiningen.core.eval :as lein]))
(defn migration-summary [project & args]
(lein/eval-in-project
project
`(do
(require '[metabase.config :as ~'config]
'[metabase.db :as ~'db]
'[metabase.driver.generic-sql.sync :as ~'sync])
(let [db# {:engine (name (config/config-kw :mb-db-type))
:details {:conn_str (db/metabase-db-conn-str)}}]
(->> (sync/table-names db#)
(map (fn [table-name#]
(println (format "\n* %s" table-name#))
(->> (sync/jdbc-columns db# table-name#)
(sort-by :column_name)
(map (fn [{:keys [~'type_name ~'column_name]}]
(println (format " * %s %s" ~'column_name ~'type_name))))
dorun)))
dorun)))))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment