Skip to content

Releases: r-world-devs/GitStats

GitStats 2.1.2

13 Nov 10:27
95d6300
Compare
Choose a tag to compare

This is a patch release which introduces some hot fixes and new data in get_commits() output.

  • Added repo_url column to output of get_commits() function (#535).
  • Fixed setting default tokens when verbose mode is set to FALSE (#525) and fixed checking token scopes for GitLab (#526).
  • Fixed get_repos_urls() output when individual repositories are set in set_*_host()(#529). Earlier the function pulled all repositories for an organization, even though, repositories were defined for the host, not whole organizations. This is similar to the solved earlier (#439).
  • Fixed getting GitLab subgroups as organizations in repositories table output when pulling repositories with code (#531).

GitStats 2.1.1

29 Oct 07:46
a12bf97
Compare
Choose a tag to compare

This is a patch release which introduces some improvements in get_R_package_usage() on speed and possibility to pull at once data on multiple R packages, new get_storage() function and some fixes for checking token scopes and setting hosts.

Features:

  • Optimized get_R_package_usage() function:
    • it is now possible to pass a vector of packages names (new packages parameter replacing old package_name) (#494),
    • on the other hand, output of the function has been limited to contain only most necessary data (removing all repository stats), making thus process of obtaining package usage faster (#474).
    • new split_output parameter has been added - when set to TRUE a list with tibbles (every element of the list for every package) instead of one tibble is returned.
  • Added possibility to get repositories for individual users with get_repos() (#492). Earlier this was only possible for GitHub organizations and GitLab groups.
  • Added new get_storage() function to retrieve data from GitStats object - whole or particular datasets (e.g. commits, repositories or R_package_usage) (#509).

Fixes:

  • Fixed getting large search responses for GitHub (#491).
  • Fixed checking token scopes (#501). If token scopes are insufficient error is returned and GitHost is not passed to GitStats. This also applies to situation when GitStats looks for default tokens (not defined by user). Earlier, if tests for token failed, an empty token was passed and GitStats was created, which was misleading for the user.
  • It is now possible to pass public GitHub host name (github.com or https://github.com) to set_github_host() (#475).
  • It is also possible to pass hosts in more flexible way than before (e.g. {host_url}, http://{host_url} or https://{host_url}) to host parameter in `set_*_host() function (#399).

2.1.0

01 Oct 07:29
08a7d85
Compare
Choose a tag to compare

New features:

  • Added new get_files_structure() function to pull files structure for a given repository with possibility to control level of directories (depth parameter) and to limit output to files matching regex argument passed to pattern parameter (#338). Together with that, get_files() function was renamed to get_files_content() to better reflect its purpose.
  • Adjusted get_files_content() so it can make use of files_structure pulled to GitStats storage with get_files_structure() function - if file_path is set to NULL and use_files_structure() parameter to TRUE (both are by default)(#467).
  • Added progress parameter to user functions to control showing of cli progress bar separately from messages (which are controlled with verbose) (#465).

Other:

  • Changed message when searching scope is set to scan whole git host (no orgs nor repos specified) from warning to info (#456).
  • Added new CI/CD jobs: deploy to gh-pages, lint and check for bumping version.
  • Mocked extensively API responses to improve tests and checks progress (#481].

2.0.2

19 Jul 07:59
9ecc7b1
Compare
Choose a tag to compare

This is a patch release with substantial improvements to some functions (get_repos(), get_files() and get_R_package_usage()), adding with_files and in_files parameters, fixing cache feature and introducing new get_repos_urls() function, a minimalist version of get_repos():

  • Added new get_repos_urls() function to fetch repository URLs (either web or API - choose with type parameter). It may return also only these repository URLs that consist of a given file or files (with passing argument to with_files parameter) or a text in code blobs (with_code parameter). This is a minimalist version of get_repos(), which takes out all the process of parsing (search response into repositories one) and adding statistics on repositories. This makes it poorer with content but faster. (#425).
  • Added with_files parameter to get_repos() function, which makes it possible to search for repositories with a given file or files and return full output for repositories.
  • It is also possible now to pass multiple code phrases to with_code parameter (as a character vector) in get_repos() and get_repos_urls() (282).
  • Added in_files parameter to get_repos() which works with with_code parameter. When both are defined, GitStats searches code blobs only in given files.
  • Removed dplyr::glimpse() from get_*() functions, so there is printing to console only if get_*() function is not assigned to the object (#426).
  • Output table of get_R_package_usage() consists now also of repository full name (#438).
  • Improved get_R_package_usage() with optimizing search of package names in DESCRIPTION and NAMESPACE files by removing filtering method and replacing it with filename: filter directly in search endpoint query (#428).
  • Fixed get_files() when scanning scope is set to repositories. Earlier, it pulled given files from whole organizations, even if scanning scope was set to repos with set_*_host(). Now it shows only files for the given repositories (#439).
  • Improved cache feature (#436).
  • verbose parameter controls now showing of the progress bars (#453).

2.0.1

14 May 10:22
cb1dbf8
Compare
Choose a tag to compare

This is a patch release with some hot issues that needed to be addressed, notably covering set_*_host() functions with verbose control, tweaking a bit verbose feature in general, fixing pulling data for GitLab subgroups and speeding up get_files() function.

Features:

  • Getting files feature has been speeded up when GitStats is set to scan whole hosts, with switching to Search API instead of pulling files via GraphQL (with iteration over organizations and repositories) (#411).
  • When setting hosts to be scanned in whole (without specifying orgs or repos) GitStats does not pull no more all organizations. Pulling all organizations from host is triggered only when user decides to pull repositories from organizations. If he decides, e.g. to pull repositories by code, there is no need to pull all organizations (which may be a time consuming process), as GitStats uses then Search API (#393).
  • It is now possible to mute messages also from set_*_host() functions with verbose_off() or verbose parameter (#413).
  • Setting verbose to FALSE does not lead to hiding output of the get_*() functions - i.e. a glimpse of table will always appear after pulling data, even if the verbose is switched off. verbose parameter serves now only the purpose to show and hide messages to user (#423).

Fixes:

  • Pulling repositories from GitLab subgroups was fixed. It did not work, as the URL of a group (org) was passed to GraphQL API the same way as to REST API, i.e. with URL sign ("%2F", instead of "/").
  • GitStats returns now proper error, when you pass wrong host URL to set_*_host() function (#415).

1.1.0

08 Jan 10:14
e42d640
Compare
Choose a tag to compare

New features:

  • pull_R_package_usage() with get_R_package_usage() functions to pull repositories where package name is found in DESCRIPTION or NAMESPACE files or code blobs with phrases related to using an R package (library(package), require(package)) (#326, #341),
  • pull_files() with get_files() to pull content of text files (#200).
  • possibility to pass specific repositories to GitStats with set_host() function by using repos parameter instead of orgs (#330).

Bug fixes:

  • fixed pulling responses when GitLab groups have private or empty content (#314),
  • fixed pulling users when pulling from multiple hosts (#312),
  • improved search API error handling.

Minor changes and features:

  • rename column names for repository output - id to repo_id and name to repo_name,
  • added a default_branch column to repositories output as a consequence of #200.

1.0.0

06 Oct 13:59
9ae656a
Compare
Choose a tag to compare

Breaking changes:

New functions:

  • added get_*_stats() functions to prepare summary stats from pulled data: repositories and commits (#276),
  • rename and refactor plot functions to one generic gitstats_plot() which takes as an input repos_stats or commits_stats class objects (#276),

New names for core functions:

  • changed names from get_* to pull_*; get_* functions are now to retrieve already pulled data from GitStats object (#294),
  • changed name from setup() to set_params() (#294),
  • changed name from set_connection() to set_host() (#271),
  • changed name from add_team_member() to set_team_member() (#271).

Major changes:

New features:

  • added setting tokens by default - if the user does have all the PATs set up in environment variables (as e.g. GITHUB_PAT or GITLAB_PAT), there is no need to pass them as an argument to set_host() (#120),
  • added pull_users() function to pull information on users (#199),
  • added possibility of scanning whole internal git platforms if no orgs are passed (#258),
  • added get_orgs() function to print all organizations (#283),
  • added resetting all settings to default with reset() function (#270)
  • added resetting language in your search preferences with reset_language() or setting language parameter to All in setup() function (#231)

Improving performance with REST and GraphQL APIs:

  • added switching to REST engine in case GraphQL fails with 502 error (#225)
  • added GraphQL engine for getting GitLab repositories by organization (#218)
  • removed contributors as basic stat when pulling repos by org and by phrase to improve speed of pulling repositories data. Added pull_repos_contributors() user function and add_contributors parameter to pull_repos() function to add conditionally information on contributors to repositories table (#235)

Minor changes:

  • handled errors with proper messages when tokens do not grant access (#242 #301),
  • in repositories output set api_url column as an address to the repository, not the host (#201),
  • fixed adding GitLab subgroups (#176),
  • exported pipe operator (%>%) (#289).

0.1.0

15 May 08:45
8ccc3c9
Compare
Choose a tag to compare

This is the first release of GitStats with given features:

  • create_gitstats() - creating GitStats object,
  • set_connection() - adding hosts to GitStats object,
  • setup() - setting search parameter to org, team or phrase, setting programming language of repositories,
  • get_repos() - pulling repositories from GitHub and GitLab API in a standardized table,
  • get_commits() - pulling commits from GitHub and GitLab API in a standardized table,
  • add_team_member() - adding team members to GitStats object.