Adb was accidentally removed. How to restore it on Mac? - adb

I have installed Android Studio 2.2 on my mac. While playing with "ln" command, i removed "adb" through incorrect arguments usage.
How can i restore the "adb"?
If i try to install SDK tools, it tries to stop adb, which can't be found.

Download platform-tools_rXX...zip for your operations system ad extract ad
https://stackoverflow.com/tags/adb/info

Related

Error: ENOENT: no such file or directory, scandir '/Documents/android-sdk-linux/build-tools' at Error (native)

I am new to Appium and I am running a selenium script with device connected and while running in terminal i am getting this error:
“Error: ENOENT: no such file or directory, scandir ‘/Documents/android-sdk-linux/build-tools’ at Error (native)”
I am running in Linux. Can you please help me out ?
You need to paste this two lines in .bashrc file
export ANDROID_HOME=/home/rijomon/Documents/android-sdk-linux/sdk
export PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools
then you will not get that error
This error is caused when Appium can not find a valid path to the Android SDK in the ANDROID_HOME environment variable
...or when the SDK installation is corrupt.
Rijo Mon's answer is correct for his system but the ANDROID_HOME path will need to be changed to point to the actual location of your installed SDK.
Install Android Studio if you aren't already using it.
Make sure only one version of Android SDK is installed in Android studio, and make sure Android Studio does not display any errors or warnings about the SDK installation.
Go to Android Studio Preferences → Appearance and Behavior → System Settings → Android SDK
Uninstall all installed Android SDK versions here by unchecking
their boxes and clicking Apply
Uninstall any other copies of the Android SDK on your system
In Android Stduio, check only one SDK version and install it by clicking Apply.
Close and re-open Android Studio (you may want to reboot your machine)
Go back into the Android SDK window in Preferences → Appearance and Behavior → System Settings → Android SDK
Confirm that Android Studio does not display any warnings about the installed Android SDK.
Make sure the ANDROID_HOME environment variable is in your bash_profile and that it points to the location of your installed SDK. For an SDK installation managed by Android Studio on OSX, this should be ~/Library/Android/sdk
The output of "ls -l ~/Library/Android/sdk" or the ls for your correct path to your SDK should now show a directory listing with the installed SDK files and folders including "build-tools" and "emulator"
Add the following line to ~/.bash_profile (OSX) or ~/.bashrc (Linux)
export ANDROID_HOME="${HOME}/Library/Android/sdk" (replace the path with your actual SDK path)
Restart your terminal or source the modified bash profile with "source ~/.bash_profile" or "source ~/.bashrc"

Use cakeresque on xampp on windows

I want to use cakeresque running on, and first I need to install PhpRedis.
When I install cakeresque with composer.json it gives me this error:
kamisama/php-resque-ex 1.3.0 requires ext-pcntl * -> the requested PHP extension > pcntl is missing from your system.
So how do I install ext-pcntl on xampp in windows?
You don't do it all, as it's not possible.
http://php.net/manual/en/pcntl.installation.php
Note:
Currently, this module will not function on non-Unix platforms (Windows).
https://github.com/kamisama/php-resque-ex#warning
Warning
php-resque requires the pcntl php extension, not available on Windows platform. Composer installation will fail if you're trying to install this package on Windows machine. If you still want to continue with the installation at your own risk, execute the composer install command with the --ignore-platform-reqs option.
https://github.com/kamisama/php-resque-ex/pull/6
So either force install kamisama/php-resque-ex and live with the limitations because of the missing PCNTL extension, or use a VM with an OS that is supported by PCNTL.

Backup and Restore option not available in pgAdmin III

I have to take backup of my database but when I right click DB and then backup The button for backup is disabled. Similarly in existing database ,not able to restore because the Restore button too disabled.
I was working fine till the time I created a new database.
How do they get enabled?
I had the same problem in ubuntu 14.04. It was necessary to install both postgresql-client-common (which contains pg_dump and pg_restore) and postgresql-client packages.
There is no need for reinstall,
just open File->Options->Binary paths and add set "PG bin path" to path where pg_dump/pg_restore is located.
Here is a solution:
$ yum install postgresql-contrib
Problem could be caused by a fact that you simply do not have pg_dump and pg_restore tools installed (or they are not visible for pgadmin).
This had happen to me when installing pgadmin3 on CentOS 7 via PostgreSQL yum repository. To resolve this I had to install package with those tools - in my case postgresql94 (PostgreSQL client programs and libraries).
On other distros you will need to find which package should be installed. AFAIK this issue is not present in Windows environment, pgadmin installer probably have all needed dependencies.
I was facing problem in restoring my database from backup, so I followed some steps:
Go to c:\ drive and find this path "C:\Program Files\PostgreSQL\13\bin"
Copy all the files from there then
past all the copied files to the given folder
"C:\Program Files\PostgreSQL\13\pgAdmin 4\runtime"
Your problem will definitely be solved.
You can go and check my video Where I showed step by step problem.
[link]
(https://youtu.be/GS3Dg0TfyFI)
Just reinstall your PGAdmin3.
We had the same problem on a Mac and after reinstallation, the right click menu showed more options like "Restore" and "Backup".
I had this issue (restore button disabled) and the problem was a corrupted dump.
So, I've created a new dump and tried again. After selecting the new file, the button became available.
in my case i'm on windows,
if python isn't installed, install it.
restart, and you're done.
I have checked in the pgadmin4 sql:
SELECT * FROM pg_available_extensions;
and got the current installed 2.1 which is not correct. You need to check on the db command line, the same query did result that the adminpack is NOT installed.
Solution: Logon to the DB on comand line and write
CREATE EXTENSION adminpack;

Golang GAE SDK on XP: Do I have to install it? Are there other ways to use the SDK on XP?

The introduction says:
Follow the instructions on the download page to install the SDK on
your computer.
But the download page has no any instructions about how to install and what to do next. Only links.
All I found is this link to WindowsInstallation:
Download and run the latest Windows installer from our downloads page
Must Windows XP users use the installer? Can they just download the Linux version and unzip it? I'd like to have a portable version rather than one that installs EXEs and registry settings, etc.
Also I do not understand what exactly do I have to choose. There are:
Google App Engine SDK 1.7.7 (.msi file)
Google App Engine SDK for Go 1.7.7 (.zip file)
I've downloaded the second. Do I need to download and install the first too? Just adding the second to the PATH and develop is exactly what I want. Is this enough?
The Linux version will have executables compiled for Linux, so you can't run those on Windows (unless you run linux under a virtual machine with VirtualBox, VMWare or similar).
No, you do not need to install something to run Go GAE on XP.
I just downloaded go_appengine_sdk_windows_386-1.7.7.zip from
here.
Unzipped it in C:\go_appengine-1.7.7
Added the folder in my PATH. The main goal is to have these files
dev_appserver.py and appcfg.py in the PATH. It is written
here. Not a must, though, only for convenience.
Installed Python 2.7.4. Only works with 2.7.4. At first I installed
the latest 3.3.1 but had to change it to 2.7.4 because Go GAE cannot
run, throws an error.
And that's all. Just created a sample script, ran C:\>dev_appserver.py myapp and opened my sample app in localhost:8080.
PROFIT.
But:
Do not know, though, what benefits the installer offer. I didn't test it.
That was just a sample script. Maybe some serious development requires installation.

can't find where BlackBerry 10 simulator was installed on MacOS, and re-install got "multiple launches of installer not allowed" error

Mac OS X Lion 10.7.5(11G63)
installer-bbndk-bb10_1_x-macosx-338-201302012246-201302032157.dmg
BlackBerry10Simulator-Installer-BB10_1_X-338-Mac-201302031817.dmg
After install the upper two dmg files, I can find qde in the launchpad, but I can not find the "BlackBerry10Simulator-BB10_n_nn.vmwarevm" file".
I want to re-install ,so I run the app "BlackBerry10Simulator-Installer.app" in Finder->devices->BlackBerry10Simulator-BB10-1-x, just get the pop-up-box saying
The Installer cannot be run.
Multiple launches of this installer is not allowed. It will now quit
, and then the installer quit.
How can I find the simulator install path, or
How can I re-Install it successfully.
P.S.
At the first time installing, I did not change anything while installing, just clicked those "next","accept..." buttons.
I think the simulator should be installed in default file path, but I don't know where is it, and can't find it even searching "BlackBerry10Simulator" in Finder.
Maybe there is something wrong while first time installing simulator?
The BB10 simulators are VMware virtual machines. On a Mac, you need to have VMWare Fusion installed in order to run the simulator VM. This is mentioned in the system requirements. All the dmg installer does is uncompress the VMware image and place it on your hard drive. I just installed this myself, and the default location seems to be:
/Users/<your username>/Documents/Virtual Machines
Inside there should be a folder Blackberry10Simulator-BB10_1_X-338 and inside that there should be BlackBerry10Simulator-BB10_1_X.vmwarevm which contains the actual virtual machine .vmx and .vmdk files.
There should also be an alias (shortcut) created on your desktop to point to this location, called Blackberry 10 Simulator.
To uninstall, there is a script in Blackberry10Simulator-BB10_1_X-338/install called uninstaller which should remove everything and allow you to install again.
Unfortunately, VMWare Fusion is not free but you can sign up for a 30-day trial in order to be able to run the simulator and test out your app.
I recently encountered this error with a different installer (but also installanywhere based). There seems to be a problem with the mirroring feature in VM Ware Fusion and the multiple install detection in Install anywhere. If you disable mirroring, I suspect the "Multiple launches of this installer is not allowed." error will no longer occur.

Resources