module CrystalDoc::Queries

Defined in:

crystaldoc/queries.cr

Constant Summary

Log = ::Log.for(self)

Class Method Summary

Class Method Detail

def self.add_featured_repo(db : Queriable, repo_id : Int32) #

[View source]
def self.current_repo_versions(db : Queriable, repo_id) : Array(String) #

[View source]
def self.find_repo(db : Queriable, user : String, proj : String, distinct : Bool = false) : Array(Repo) #

[View source]
def self.get_repo_data(db : Queriable, repo_id : Int32) : Ext::Data | Nil #

[View source]
def self.get_repo_id(db : Queriable, source_url : String) #

[View source]
def self.insert_doc_job(db : Queriable, version_id : Int32, priority : Int32) #

[View source]
def self.insert_repo_version(db : Queriable, repo_id : Int32, tag : String, nightly : Bool) : Int32 #

[View source]
def self.latest_version(db : Queriable, service : String, username : String, project_name : String) : String #

Returns the current latest version as a string for a service/username/project_name combination


[View source]
def self.mark_version_invalid(db : Queriable, commit : String, service : String, username : String, project_name : String) #

[View source]
def self.mark_version_valid(db : Queriable, commit : String, service : String, username : String, project_name : String) #

[View source]
def self.popular_repos(db : Queriable, count : Int32 = 10) : Array(Repo) #

[View source]
def self.random_repo(db : Queriable) : Repo #

[View source]
def self.recently_updated_repos(db : Queriable, count : Int32 = 10) : Array(Repo) #

[View source]
def self.refresh_repo_versions(db : Queriable, repo_id : Int32) #

[View source]
def self.regenerate_all_docs(db : Queriable) : Int32 #

[View source]
def self.remove_featured_repo(db : Queriable, repo_id : Int32) #

[View source]
def self.repo_count(db : Queriable) #

[View source]
def self.repo_exists(db : Queriable, service : String, username : String, project_name : String) : Bool #

[View source]
def self.repo_exists(db : Queriable, source_url : String) : Bool #

[View source]
def self.repo_exists_and_valid(db : Queriable, service : String, username : String, project_name : String) : Bool #

[View source]
def self.repo_from_source(db : Queriable, source_url : String) : Array(Repo) #

[View source]
def self.repo_needs_updating(db : Queriable) : Array(Repo) #

[View source]
def self.repo_nightly_version_id(db : Queriable, service : String, username : String, project_name : String) : Int32 #

[View source]
def self.repo_version_exists(db : Queriable, service : String, username : String, project_name : String, version : String) : Bool #

[View source]
def self.repo_version_valid_count(db : Queriable) #

[View source]
def self.update_latest_repo_version(db : Queriable, repo_id : Int32, latest_version_id : Int32) #

[View source]
def self.update_repo_data(db : Queriable, repo_id : Int32, data : Ext::Data) #

[View source]
def self.upsert_repo_status(db : Queriable, last_commit : String, repo_id : Int32) #

[View source]
def self.versions_json(db : Queriable, service : String, username : String, project_name : String) : String #

[View source]