2Answers
  • 13
name

A PHP Error was encountered

Severity: Notice

Message: Undefined index: userid

Filename: views/question.php

Line Number: 191

Backtrace:

File: /home/prodcxja/public_html/questions/application/views/question.php
Line: 191
Function: _error_handler

File: /home/prodcxja/public_html/questions/application/controllers/Questions.php
Line: 433
Function: view

File: /home/prodcxja/public_html/questions/index.php
Line: 315
Function: require_once

name Punditsdkoslkdosdkoskdo

Android Studio Build/Clean

In an attempt to compile external jars, I have to use the terminal and do a clean. However, when I go into the root directory of my project and execute

gradlew clean

I get the following message:

-bash: gradlew: command not found

Here's a screenshot of my application folder's home directory.

Let me know if you need anything else, I'm not sure why this is happening.

      • 1
    • Maybe that's it- I thought it came with Android-studio. Was I mistaken? Doesn't android studio use gradle to compile in the first place? gradle clean doesn't help.
      • 2
    • Ok. I think that android studio installs gradle but doesn't add it to system PATH. If you want to build applications using command line instenad of IDE just find where android studio installed gradle and add it's path to PATH environment.

gradlew is not in your global path. To execute the 'clean' task (or any task for that matter) using the gradle wrapper (gradlew) in your project directory in your terminal, specify the current directory with the './':

./gradlew clean
  • 96
Reply Report
      • 2
    • Running mac, you also have to do "chmod 755 gradlew" on the file before to make it executable.
      • 2
    • Going with @SimonBengtsson, if you are using linux you must do "sudo chmod +x gradlew" before you do the "./gradlew clean" to make sure it is executable. It did not work until I did this.