Comments (8)
Trying to decide how to proceed with moving the data.
No function version data exists in the DB right now, so I'll start by adding the ability to parse and store to the analyzer, and add a version
column to the functions
table. Then, write a migration to add the function_versions
table, and populate that table with data from the functions
table.
Effectively, whatever data exists in the functions
table (including the new version
column) will become the first version of that var as far as CD is concerned.
from clojuredocs.
Updated clojuredocs-analyzer to store version in the newly created functions.version
column.
Core import: http://gist.github.com/605416
Contrib import: http://gist.github.com/605424
Also imported ring, version was added correctly.
from clojuredocs.
Migrations are done, schema now looks like this:
function function_versions
-------------- --------------------------
library <------ function_id
ns doc
name source
etc etc
I also considered keeping line / file / doc / etc in the functions
table, and only fetch older versions when requested by the user. This would get rid of the join that will be made every time somebody requests a function, but I'll leave that as a future optimization path.
from clojuredocs.
clojuredocs-analzyer has been updated to import to the new versioning schema: analyzer commit
As of now, all libraries that are run through the analyzer now have their version numbers parsed as well (only lein supported atm). New versions are now stored only if the version number on the lib is different than previous versions.
Long-term todos:
- Version sorting (sorts by created_at date for now)
Next up is importing older versions of core and contrib for test data to implement the versions UI on top of.
from clojuredocs.
Just ran an import of 1.3.0-alpha1, 801 vars vs 781 vars in 1.2.0
Looks like the unchecked-
* vars were removed: http://gist.github.com/610976 (line 1655)
The analyzer will have to be changed, vars should no longer be removed.
from clojuredocs.
So a bit of churn here.
Instead of the changes outlined above, I've gone the simpler route of adding version columns to the libraries
, namespaces
, and functions
tables. Additionally I've added a current
column to the libraries
table to specify the primary version of a specific library.
I feel that, while not as correct as the functions -> function_versions (and libraries -> library_versions, namespaces -> namespace_versions) method, it's simpler to reason about.
Relevant changes are in the var-versioning-simple branch.
Also, a bit of work on the UI has been done:
macroexpand-1 1.2.0 screenshot
macroexpand-1 1.3.0-alpha1 screenshot
Side note: URLs have been prettified so
becomes
http://clojuredocs.org/clojure_core/current/clojure.core/macroexpand-1
and
becomes
http://clojuredocs.org/clojure_core/current/clojure.core/even_q
from clojuredocs.
Switched from using the word 'current' to 'stable' to describe the latest production version of a library.
Versioning UI updates
Clojure 1.2.0 is the 'stable' version here:
Stable version var page showing drop-down
After clicking on permalink (notice version number of stable gets added to url)
After clicking on non-stable version
Switched 'stable' version to 1.3.0-alpha1:
from clojuredocs.
Finished up var-versioning, rebased into master
from clojuredocs.
Related Issues (20)
- Voting on answers HOT 3
- Twitter icon broken on the homepage HOT 1
- Can't use search bar if width is under 768px.
- Html injection spam
- Missing vars in clojure.xml
- Need to update Kira logo HOT 1
- Link to core.match documentation similarly to link to core.async HOT 1
- Add tools.build doc
- Update ClojureDocs to v1.11 HOT 6
- Bad docstring for if
- Seach form hidden on clojure.string page
- 4clojure link is dead HOT 2
- Document the options to clojure.java.io.{reader,writer,input-stream,output-stream}
- DEFN podcast invitation
- ClojureScript support in docs and output? HOT 1
- Slow responses from the live site today HOT 8
- Add clojure.data.csv?
- Experience notes spinning up clojuredocs in local HOT 1
- Request for, :>>, to be searchable as, ->>, and, ->, are.
- Add Splash to Clojure in Production
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from clojuredocs.