Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/clarkwinkelmann/flarum-query
Experimental
https://github.com/clarkwinkelmann/flarum-query
Last synced: about 2 months ago
JSON representation
Experimental
- Host: GitHub
- URL: https://github.com/clarkwinkelmann/flarum-query
- Owner: clarkwinkelmann
- Created: 2020-03-08T02:49:22.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-07T04:34:37.000Z (about 2 years ago)
- Last Synced: 2024-10-14T10:48:37.703Z (3 months ago)
- Language: PHP
- Homepage: https://query.flarum.dev/
- Size: 769 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Flarum "big" query
An attempt at bringing big data to Flarum.
This tool let us analyze all extensions via SQL queries.Try it out at
Some example queries:
### Routes defined by multiple extensions
```sql
select method, path, count(1) as count from route_definitions
where version = 'latest'
group by method, path
having count > 1
order by count desc
```### Packages defining translations that don't start with their extension ID
```sql
select d.package, count(1) as string_not_matching_count from translation_definitions d
join extensions e on e.package = d.package
where version = 'latest' and `key` not like concat(flarumid, '.%')
group by d.package
order by string_not_matching_count desc
```### Detailed list of translations used by packages that don't start with their extension ID
```sql
select d.package, flarumid, `key` from translation_usages d
join extensions e on e.package = d.package
where version = 'latest' and `key` not like concat(flarumid, '.%')
order by d.package
```### How many extensions use each license
```sql
select license, count(1) as count from releases
where version = 'latest'
group by license
order by count desc
```### All packages that don't use the MIT license
```sql
select package, license, title, description from releases
where license != 'MIT' and version = 'latest'
order by package
```### Most imported PHP classes from the Flarum namespace
```sql
select class, count(1) as count from php_imports
where version = 'latest' and class like 'Flarum%' and package not like 'flarum/%'
group by class
order by count desc
```### Most imported PHP classes in packages released recently
```sql
select class, count(distinct i.package) as extensions_count, count(1) as import_count from php_imports i
join releases r on r.package = i.package and r.version = i.version
where i.version = 'latest' and class like 'Flarum%' and i.package not like 'flarum/%' and date >= '2020-01-01'
group by class
order by extensions_count desc
```