Commit Graph

70 Commits

Author SHA1 Message Date
Lauris BH
289ac3d9f0 Sync with linguist 7.12.1 2020-11-15 14:32:56 +02:00
Lauris BH
bc76dd38b0 sync to the latest github/linguist v7.11.1 2020-10-12 12:32:48 +03:00
Lauris BH
7c562a6c34 sync to the latest github/linguist v7.11.0 2020-09-17 10:34:41 +03:00
Miguel Molina
8ff885a3a8
implement IsGenerated helper to filter out generated files
Closes #17

Implements the IsGenerated helper function to filter out generated
files using the rules and matchers in:
- https://github.com/github/linguist/blob/master/lib/linguist/generated.rb

Since the vast majority of matchers have very different logic, it cannot
be autogenerated directly from linguist like other logics in enry, so it's
translated by hand.

There are three different types of matchers in this implementation:
- By extension, which mark as generated based only in the extension. These
  are the fastest matchers, so they're done first.
- By file name, which matches patterns against the filename. These
  are performed in second place. Unlike linguist, we try to use string
  functions instead of regexps as much as possible.
- Finally, the rest of the matchers, which go into the content and try
  to identify if they're generated or not based on the content. Unlike
  linguist, we try to only read the content we need and not split it
  all unless it's necessary and use byte functions instead of regexps
  as much as possible.

Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
2020-05-28 08:55:13 +02:00
Máximo Cuadros
b851ee83ad
IsTest function for top 10 languages 2020-04-06 16:23:48 +02:00
Alexander Bezzubov
4fb0b4cc5e
doc: add coloring to the ToC
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2020-03-31 11:20:06 +02:00
Lauris BH
97a26011a9 Return group color if language has none 2020-03-31 09:30:27 +03:00
Alexander Bezzubov
6a09a2a684
doc: update badges
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2020-03-30 19:42:03 +02:00
Alexander Bezzubov
64d02e5441
doc: re-structure README by use case, update links
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2020-03-30 19:31:53 +02:00
Lauris BH
9030d3671b sync to the latest github/linguist v7.9.0 2020-03-30 01:25:57 +03:00
Máximo Cuadros
84efad7693
*: module rename to go-enry/go-enry/v4 2020-03-19 17:31:29 +01:00
Alexander Bezzubov
bc5e031cee Drop src-d org ref except for issues
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2020-03-19 14:04:36 +01:00
Alexander Bezzubov
c7272bd4f1
address review feedback
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-10-29 18:11:35 +01:00
Alexander Bezzubov
324cb1d7c9
doc: cleanup and simplify
Make it shorter and more structured, update ToC
remove ref from links, etc

Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-10-29 15:49:16 +01:00
M. J. Fromberger
bf29b9a924 Use conditional composition instead of sequential.
Signed-off-by: M. J. Fromberger <michael.j.fromberger@gmail.com>
2019-10-07 09:39:07 -07:00
M. J. Fromberger
7763fcde19 docs: Update CLI installation instructions.
Fixes #243. The default behaviour for `go get` has changed slightly and we now
need to either provide a module context or disable modules for installation to
work correctly.

Also remove a now-obsolete reference to the source{d} engine CLI.

Signed-off-by: M. J. Fromberger <michael.j.fromberger@gmail.com>
2019-10-07 08:34:50 -07:00
M. J. Fromberger
e9af1d7187 Improve download and usage examples in README.md.
Addresses #239. The `go get` command fetches the command-line tool, and does
not match the import path for the library. To make things more clear:

1. Mention explicitly that `go get` fetches the CLI. Also, to avoid potential
   issues with pre-modules Go versions, do the fetch in /tmp.

2. Include an import path explicitly in the source examples.

3. Mention explicitly how to import enry into a modules build.

Signed-off-by: M. J. Fromberger <michael.j.fromberger@gmail.com>
2019-08-07 12:04:41 -07:00
Alexander Bezzubov
9bd22dae54
doc: fix typo in MD link
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-08-06 17:22:11 +02:00
Lauris Bukšis-Haberkorns
4e3e15e80d
Sync to linguist v7.5.1
Signed-off-by: Lauris BH <lauris@nix.lv>
2019-08-06 17:18:01 +03:00
Alexander Bezzubov
e1fbfaea60
doc: code review feedback
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-08-06 11:57:34 +02:00
Alexander Bezzubov
85641846f8
doc: add documentation some ❤️
- add ToC
 - hide less relevant section under th #misc
 - update examples
 - clarify linguist sync practice

Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-08-05 12:42:16 +02:00
Alexander Bezzubov
20c6d2845a
build: gopkg.in -> github.com imports
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-04-12 11:49:16 +02:00
Alexander
7a6e8ca783
Merge pull request #214 from bzz/fix-cli-accuracy
CLI: sync report logic \w Linguist
2019-04-09 16:32:52 +02:00
M. J. Fromberger
bad147cb72
Update README.md
Co-Authored-By: bzz <bzz@users.noreply.github.com>
2019-04-08 18:00:43 +02:00
Alexander Bezzubov
416afb45fc
doc: better wording in 'divergences from linguist' section
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-04-08 15:58:46 +02:00
Alexander Bezzubov
94e8598d3d
doc: update TravisCI links
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-04-04 15:27:12 +02:00
Alexander
32336ac554 Update README.md
Co-Authored-By: SuhaibMujahid <suhaibmujahid@gmail.com>
Signed-off-by: Suhaib Mujahid <suhaibmujahid@gmail.com>
2019-04-03 14:59:31 -04:00
Alexander Bezzubov
c9f1793a78
doc: update godoc and README \w supported features
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2019-04-03 18:51:54 +02:00
Suhaib Mujahid
badbfd06e5 Update README.md
Signed-off-by: Suhaib Mujahid <suhaibmujahid@gmail.com>
2019-04-01 18:49:01 -04:00
Alexander
3499750785
Sync to linguist 7.2.0: heuristics.yml support (#189)
Sync \w Github Linguist v7.2.0

Includes new way of handling `heuristics.yml` and
all `./data/*` re-generated using Github Linguist [v7.2.0](https://github.com/github/linguist/releases/tag/v7.2.0)
release tag.

 - many new languages
 - better vendoring detection
 - update doc on update&known issues.
2019-02-14 12:47:45 +01:00
Alexander Bezzubov
890afc400f
bench: update enry v1.6.7 vs linguist v7.1.3
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2018-12-27 14:50:48 +01:00
Alexander Bezzubov
db21cd6557
doc: add instructions for reproducing benchmarks
Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2018-12-27 14:50:43 +01:00
Alexander
ef50154395
Maintenance: batch of minor changes (#183)
* exclude build artifacts from git
* build: simplify building by using src-d/ci
* bench: simplify&fix shell runners
* build: simplify benchmarks* targets
* test: remove dependency on single test suite
* doc: rel image link + linguist cli difference highlight
* suggestions from code review
* bench: add fail fast to all shell runners

Signed-off-by: Alexander Bezzubov <bzz@apache.org>
2018-12-27 11:55:34 +01:00
Francesc Campoy
760c19cb19
Include reference to source{d} Engine
Signed-off-by: Francesc Campoy <campoy@golang.org>
2018-11-07 12:13:42 -08:00
Silvia O'Dwyer
abaedb962b Rectified stray typos in the main README file (#174)
* Fixe typo in the README file.

Signed-off-by: Silvia O'Dwyer <silviaodwyer119@yahoo.ie>
2018-10-29 23:09:42 -04:00
Antonio Jesus Navarro Perez
15bb13117f Refactor Oniguruma integration
Instead of use a command to change imports before build, using a build tag to generate the correct binary.

This will allow applications to compile enry using oniguruma with less troubles.

Signed-off-by: Antonio Jesus Navarro Perez <antnavper@gmail.com>
2018-08-29 18:01:13 +03:00
Zeger-Jan van de Weg
7923b86ebd
Rename onigumura to oniguruma
This change names the dependency like its called. The link to the
package was correct, but all other references were renamed where I could
find time with git grep.

Signed-off-by: Zeger-Jan van de Weg <git@zjvandeweg.nl>
2018-03-28 21:34:54 +02:00
Vadim Markovtsev
db0e1e0d71 Fix readme flaws
Signed-off-by: Vadim Markovtsev <vadim@sourced.tech>
2017-10-26 17:04:31 +02:00
Vadim Markovtsev
52ab47de4d Add the readme
Signed-off-by: Vadim Markovtsev <vadim@sourced.tech>
2017-10-26 17:04:31 +02:00
David Pordomingo
ca5f3d9fd6
Implement docsrv
Signed-off-by: David Pordomingo <David.Pordomingo.F@gmail.com>
2017-10-16 08:40:51 +02:00
Alfredo Beaumont
241f4454c4 docs: Improve explanation of the origin of the name.
Signed-off-by: Alfredo Beaumont <alfredo.beaumont@gmail.com>
2017-10-04 17:48:13 +02:00
Juanjo Alvarez
71b516a7bd
tmp
Signed-off-by: Juanjo Alvarez <juanjo@sourced.tech>
2017-10-04 17:25:03 +02:00
Juanjo Alvarez
6b2c55abb2
Grammar and style changes.
Signed-off-by: Juanjo Alvarez <juanjo@sourced.tech>
2017-10-04 17:25:01 +02:00
Alfredo Beaumont
9caa35ac2e docs: Some README fixes
Signed-off-by: Alfredo Beaumont <alfredo.beaumont@gmail.com>
2017-10-04 16:53:26 +02:00
Alexander Bezzubov
b73364d147 Add ability to publish final jar locally 2017-08-11 15:09:14 +02:00
Alexander
8003c102eb Update README.md
Project rename artefacts
2017-07-25 09:15:50 +02:00
Alfredo Beaumont
77db3446cf Merge pull request #77 from abeaumont/feature/replace-mit-by-apache2-license
legal: Replace MIT by Apache2 license
2017-07-19 12:26:20 +02:00
Manuel Carmona
ddeb568f38 fixed histogram's url 2017-07-18 15:26:13 +02:00
Alfredo Beaumont
3f3d1c0e70 legal: Replace MIT by Apache2 license 2017-07-14 18:01:08 +02:00
Manuel Carmona
24e751f821 document the sync with lignuist 2017-07-14 15:19:29 +02:00