Skip to content
This repository has been archived by the owner on Jul 31, 2023. It is now read-only.

fix: yard syntax #673

Merged
merged 1 commit into from
Oct 30, 2020
Merged

fix: yard syntax #673

merged 1 commit into from
Oct 30, 2020

Conversation

graceful-potato
Copy link
Contributor

Fix #560
Changes:

  • add separate rule for @see tag - first argument of this tag could be URL

  • add separate rule for @!attribute and @!macro tags - in these tags name goes after brackets

  • change end regex in rules - now you dont need to make indentations on dividing empty lines

  • add numbers to parameter names in tags

  • add numbers, trailing ? and ! to hash keys names in @option tag

  • add additional scope to hash keys in @option tag comment.line.hashkey.yard.ruby

  • The build passes

  • TSLint is mostly happy

  • Prettier has been run

@codecov
Copy link

codecov bot commented Oct 27, 2020

Codecov Report

Merging #673 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master    #673   +/-   ##
======================================
  Coverage    5.08%   5.08%           
======================================
  Files          10      10           
  Lines         118     118           
  Branches       20      20           
======================================
  Hits            6       6           
  Misses        112     112           
Flag Coverage Δ
#language_server_ruby 5.08% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 70de88e...a4f654f. Read the comment docs.

@graceful-potato
Copy link
Contributor Author

several tags are not so simple and they support multiple ways of definition
for example:

@attr name [Types] description
@attr [Types] name description

@attr_reader name [Types] description
@attr_reader [Types] name description

@attr_writer name [Types] description
@attr_writer [Types] name description

@param name [Types] description
@param [Types] name description

@yieldparam name [Types] description
@yieldparam [Types] name description

I will try to add rules for these tags later

@graceful-potato
Copy link
Contributor Author

graceful-potato commented Oct 29, 2020

  • Changed regexes to match tags above correctly.
  • Removed comment.line.yard.ruby (I don't really understand why this scope is needed)
  • Added scope comment.line.defaultvalue.yard.ruby for default value in @option tag

@graceful-potato graceful-potato force-pushed the iss560 branch 3 times, most recently from b291204 to c0901ca Compare October 29, 2020 23:41
@wingrunr21 wingrunr21 merged commit fdcd271 into rubyide:master Oct 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Yard syntax highlighting incorrect for @ sign and when numbers are encountered in a line
2 participants