-
Notifications
You must be signed in to change notification settings - Fork 225
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shell error with rake task #346
Comments
@lloydwatkin Weird. What version of |
Latest 2.4.3 |
@lloydwatkin Could you share your |
# frozen_string_literal: true
if defined?(Rails) && (Rails.env.development? || Rails.env.test?)
require "rubycritic/rake_task"
RubyCritic::RakeTask.new do |task|
task.name = 'rubycritic'
task.options = '--mode-ci --format json --no-browser'
task.verbose = true
task.paths = FileList[
'app/errors',
'app/jobs',
'app/serializers',
'app/tasks',
'app/assets',
'app/exceptions',
'app/mailers',
'app/services',
'app/uploaders',
'app/controllers',
'app/helpers',
'app/models',
'app/states',
'app/views',
]
end
end |
I am getting the same error, latest version, and I am using the command line. |
UPDATE I tested this a number of ways, and it is only occurring on my github actions CI setup when I include the It does not occur with this setup below.
|
Hi! I'm having exactly the same issue trying to run the ci mode en a gitlab CI runner. I've realised (it seems) that when the error appears, the switch from master to the current branch to compare doesn't occur, this can also be seen in the first comment of this issue (the log line saying 'Switched to branch ...' is not there). Note that I'm not even using bundler or the project Gemfile to run rubycritic (just to speed up the pipeline), just checking out the code and installing rubycritic alone, all other modes look ok, just having issues on this specific case using ci mode. |
I faced the same issue with GitHub Actions. When using the following code, - name: Rubycritic
run: |
git branch
gem install rubycritic
rubycritic
- name: Rubycritic
run: |
git checkout -b ${{ github.head_ref}} # need check out
gem install rubycritic
rubycritic |
Fix issue whitesmith#346 This commit prevents `sh: 1: Syntax error: "(" unexpected` error and completes the run with compare mode successfully.
Fix issue #346 This commit prevents `sh: 1: Syntax error: "(" unexpected` error and completes the run with compare mode successfully. Co-authored-by: Ernesto Tagwerker <[email protected]>
Hey, I think this was fixed in #424 and can be closed. |
The text was updated successfully, but these errors were encountered: