Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2895525
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
48 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/resources/sql/patches/20131004.dxreviewers.php b/resources/sql/patches/20131004.dxreviewers.php
index 3904613eb3..8ff3bc32f8 100644
--- a/resources/sql/patches/20131004.dxreviewers.php
+++ b/resources/sql/patches/20131004.dxreviewers.php
@@ -1,53 +1,53 @@
<?php
$table = new DifferentialRevision();
$conn_w = $table->establishConnection('w');
// NOTE: We migrate by revision because the relationship table doesn't have
// an "id" column.
foreach (new LiskMigrationIterator($table) as $revision) {
$revision_id = $revision->getID();
$revision_phid = $revision->getPHID();
echo "Migrating reviewers for D{$revision_id}...\n";
$reviewer_phids = queryfx_all(
$conn_w,
'SELECT objectPHID FROM %T WHERE revisionID = %d
AND relation = %s ORDER BY sequence',
'differential_relationship',
$revision_id,
'revw');
$reviewer_phids = ipull($reviewer_phids, 'objectPHID');
if (!$reviewer_phids) {
continue;
}
$editor = id(new PhabricatorEdgeEditor())
->setActor(PhabricatorUser::getOmnipotentUser());
foreach ($reviewer_phids as $dst) {
if (phid_get_type($dst) == PhabricatorPHIDConstants::PHID_TYPE_UNKNOWN) {
// At least one old install ran into some issues here. Skip the row if we
// can't figure out what the destination PHID is. See here:
- // https://github.com/facebook/phabricator/pull/507
+ // https://github.com/phacility/phabricator/pull/507
continue;
}
$editor->addEdge(
$revision_phid,
PhabricatorEdgeConfig::TYPE_DREV_HAS_REVIEWER,
$dst,
array(
'data' => array(
'status' => DifferentialReviewerStatus::STATUS_ADDED,
),
));
}
$editor->save();
}
echo "Done.\n";
diff --git a/scripts/install/install_rhel-derivs.sh b/scripts/install/install_rhel-derivs.sh
index a09949f29b..58753c038c 100755
--- a/scripts/install/install_rhel-derivs.sh
+++ b/scripts/install/install_rhel-derivs.sh
@@ -1,145 +1,145 @@
#!/bin/bash
confirm() {
echo "Press RETURN to continue, or ^C to cancel.";
read -e ignored
}
RHEL_VER_FILE="/etc/redhat-release"
if [[ ! -f $RHEL_VER_FILE ]]
then
echo "It looks like you're not running a Red Hat-derived distribution."
echo "This script is intended to install Phabricator on RHEL-derived"
echo "distributions such as RHEL, Fedora, CentOS, and Scientific Linux."
echo "Proceed with caution."
confirm
fi
echo "PHABRICATOR RED HAT DERIVATIVE INSTALLATION SCRIPT";
echo "This script will install Phabricator and all of its core dependencies.";
echo "Run it from the directory you want to install into.";
echo
RHEL_REGEX="release ([0-9]+)\."
if [[ $(cat $RHEL_VER_FILE) =~ $RHEL_REGEX ]]
then
RHEL_MAJOR_VER=${BASH_REMATCH[1]}
else
echo "Ut oh, we were unable to determine your distribution's major"
echo "version number. Please make sure you're running 6.0+ before"
echo "proceeding."
confirm
fi
if [[ $RHEL_MAJOR_VER < 6 && $RHEL_MAJOR_VER > 0 ]]
then
echo "** WARNING **"
echo "A major version less than 6 was detected. Because of this,"
echo "several needed dependencies are not available via default repos."
echo "Specifically, RHEL 5 does not have a PEAR package for php53-*."
echo "We will attempt to install it manually, for APC. Please be careful."
confirm
fi
echo "Phabricator will be installed to: $(pwd).";
confirm
echo "Testing sudo/root..."
if [[ $EUID -ne 0 ]] # Check if we're root. If we are, continue.
then
sudo true
SUDO="sudo"
if [[ $? -ne 0 ]]
then
echo "ERROR: You must be able to sudo to run this script, or run it as root.";
exit 1
fi
fi
if [[ $RHEL_MAJOR_VER == 5 ]]
then
# RHEL 5's "php" package is actually 5.1. The "php53" package won't let us install php-pecl-apc.
# (it tries to pull in php 5.1 stuff) ...
yum repolist | grep -i epel
if [ $? -ne 0 ]; then
echo "It doesn't look like you have the EPEL repo enabled. We are to add it"
echo "for you, so that we can install git."
$SUDO rpm -Uvh http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
fi
YUMCOMMAND="$SUDO yum install httpd git php53 php53-cli php53-mysql php53-process php53-devel php53-gd gcc wget make pcre-devel mysql-server"
else
# RHEL 6+ defaults with php 5.3
YUMCOMMAND="$SUDO yum install httpd git php php-cli php-mysql php-process php-devel php-gd php-pecl-apc php-pecl-json php-mbstring mysql-server"
fi
echo "Dropping to yum to install dependencies..."
echo "Running: ${YUMCOMMAND}"
echo "Yum will prompt you with [Y/n] to continue installing."
$YUMCOMMAND
if [[ $? -ne 0 ]]
then
echo "The yum command failed. Please fix the errors and re-run this script."
exit 1
fi
if [[ $RHEL_MAJOR_VER == 5 ]]
then
# Now that we've ensured all the devel packages required for pecl/apc are there, let's
# set up PEAR, and install apc.
echo "Attempting to install PEAR"
wget http://pear.php.net/go-pear.phar
$SUDO php go-pear.phar && $SUDO pecl install apc
fi
if [[ $? -ne 0 ]]
then
echo "The apc install failed. Continuing without APC, performance may be impacted."
fi
pidof httpd 2>&1 > /dev/null
if [[ $? -eq 0 ]]
then
echo "If php was installed above, please run: /etc/init.d/httpd graceful"
else
echo "Please remember to start the httpd with: /etc/init.d/httpd start"
fi
pidof mysqld 2>&1 > /dev/null
if [[ $? -ne 0 ]]
then
echo "Please remember to start the mysql server: /etc/init.d/mysqld start"
fi
confirm
if [[ ! -e libphutil ]]
then
- git clone git://github.com/facebook/libphutil.git
+ git clone git://github.com/phacility/libphutil.git
else
(cd libphutil && git pull --rebase)
fi
if [[ ! -e arcanist ]]
then
- git clone git://github.com/facebook/arcanist.git
+ git clone git://github.com/phacility/arcanist.git
else
(cd arcanist && git pull --rebase)
fi
if [[ ! -e phabricator ]]
then
- git clone git://github.com/facebook/phabricator.git
+ git clone git://github.com/phacility/phabricator.git
else
(cd phabricator && git pull --rebase)
fi
echo
echo
echo "Install probably worked mostly correctly. Continue with the 'Configuration Guide':";
echo
echo " http://www.phabricator.com/docs/phabricator/article/Configuration_Guide.html";
diff --git a/scripts/install/install_ubuntu.sh b/scripts/install/install_ubuntu.sh
index e736b7128f..265d044883 100755
--- a/scripts/install/install_ubuntu.sh
+++ b/scripts/install/install_ubuntu.sh
@@ -1,92 +1,92 @@
#!/bin/bash
confirm() {
echo "Press RETURN to continue, or ^C to cancel.";
read -e ignored
}
GIT='git'
LTS="Ubuntu 10.04"
ISSUE=`cat /etc/issue`
if [[ $ISSUE != Ubuntu* ]]
then
echo "This script is intended for use on Ubuntu, but this system appears";
echo "to be something else. Your results may vary.";
echo
confirm
elif [[ `expr match "$ISSUE" "$LTS"` -eq ${#LTS} ]]
then
GIT='git-core'
fi
echo "PHABRICATOR UBUNTU INSTALL SCRIPT";
echo "This script will install Phabricator and all of its core dependencies.";
echo "Run it from the directory you want to install into.";
echo
ROOT=`pwd`
echo "Phabricator will be installed to: ${ROOT}.";
confirm
echo "Testing sudo..."
sudo true
if [ $? -ne 0 ]
then
echo "ERROR: You must be able to sudo to run this script.";
exit 1;
fi;
echo "Installing dependencies: git, apache, mysql, php...";
echo
set +x
sudo apt-get -qq update
sudo apt-get install \
$GIT mysql-server apache2 dpkg-dev \
php5 php5-mysql php5-gd php5-dev php5-curl php-apc php5-cli php5-json
# Enable mod_rewrite
sudo a2enmod rewrite
HAVEPCNTL=`php -r "echo extension_loaded('pcntl');"`
if [ $HAVEPCNTL != "1" ]
then
echo "Installing pcntl...";
echo
apt-get source php5
PHP5=`ls -1F | grep '^php5-.*/$'`
(cd $PHP5/ext/pcntl && phpize && ./configure && make && sudo make install)
else
echo "pcntl already installed";
fi
if [ ! -e libphutil ]
then
- git clone git://github.com/facebook/libphutil.git
+ git clone git://github.com/phacility/libphutil.git
else
(cd libphutil && git pull --rebase)
fi
if [ ! -e arcanist ]
then
- git clone git://github.com/facebook/arcanist.git
+ git clone git://github.com/phacility/arcanist.git
else
(cd arcanist && git pull --rebase)
fi
if [ ! -e phabricator ]
then
- git clone git://github.com/facebook/phabricator.git
+ git clone git://github.com/phacility/phabricator.git
else
(cd phabricator && git pull --rebase)
fi
echo
echo
echo "Install probably worked mostly correctly. Continue with the 'Configuration Guide':";
echo
echo " http://www.phabricator.com/docs/phabricator/article/Configuration_Guide.html";
echo
echo "You can delete any php5-* stuff that's left over in this directory if you want.";
diff --git a/src/applications/repository/engine/PhabricatorRepositoryPullEngine.php b/src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
index e935740743..5ce19f875f 100644
--- a/src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
+++ b/src/applications/repository/engine/PhabricatorRepositoryPullEngine.php
@@ -1,470 +1,470 @@
<?php
/**
* Manages execution of `git pull` and `hg pull` commands for
* @{class:PhabricatorRepository} objects. Used by
* @{class:PhabricatorRepositoryPullLocalDaemon}.
*
* This class also covers initial working copy setup through `git clone`,
* `git init`, `hg clone`, `hg init`, or `svnadmin create`.
*
* @task pull Pulling Working Copies
* @task git Pulling Git Working Copies
* @task hg Pulling Mercurial Working Copies
* @task svn Pulling Subversion Working Copies
* @task internal Internals
*/
final class PhabricatorRepositoryPullEngine
extends PhabricatorRepositoryEngine {
/* -( Pulling Working Copies )--------------------------------------------- */
public function pullRepository() {
$repository = $this->getRepository();
$is_hg = false;
$is_git = false;
$is_svn = false;
$vcs = $repository->getVersionControlSystem();
$callsign = $repository->getCallsign();
switch ($vcs) {
case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN:
// We never pull a local copy of non-hosted Subversion repositories.
if (!$repository->isHosted()) {
$this->skipPull(
pht(
"Repository '%s' is a non-hosted Subversion repository, which ".
"does not require a local working copy to be pulled.",
$callsign));
return;
}
$is_svn = true;
break;
case PhabricatorRepositoryType::REPOSITORY_TYPE_GIT:
$is_git = true;
break;
case PhabricatorRepositoryType::REPOSITORY_TYPE_MERCURIAL:
$is_hg = true;
break;
default:
$this->abortPull(pht('Unknown VCS "%s"!', $vcs));
}
$callsign = $repository->getCallsign();
$local_path = $repository->getLocalPath();
if ($local_path === null) {
$this->abortPull(
pht(
"No local path is configured for repository '%s'.",
$callsign));
}
try {
$dirname = dirname($local_path);
if (!Filesystem::pathExists($dirname)) {
Filesystem::createDirectory($dirname, 0755, $recursive = true);
}
if (!Filesystem::pathExists($local_path)) {
$this->logPull(
pht(
"Creating a new working copy for repository '%s'.",
$callsign));
if ($is_git) {
$this->executeGitCreate();
} else if ($is_hg) {
$this->executeMercurialCreate();
} else {
$this->executeSubversionCreate();
}
} else {
if (!$repository->isHosted()) {
$this->logPull(
pht(
"Updating the working copy for repository '%s'.",
$callsign));
if ($is_git) {
$this->executeGitUpdate();
} else if ($is_hg) {
$this->executeMercurialUpdate();
}
}
}
if ($repository->isHosted()) {
if ($is_git) {
$this->installGitHook();
} else if ($is_svn) {
$this->installSubversionHook();
} else if ($is_hg) {
$this->installMercurialHook();
}
foreach ($repository->getHookDirectories() as $directory) {
$this->installHookDirectory($directory);
}
}
} catch (Exception $ex) {
$this->abortPull(
pht('Pull of "%s" failed: %s', $callsign, $ex->getMessage()),
$ex);
}
$this->donePull();
return $this;
}
private function skipPull($message) {
$this->log('%s', $message);
$this->donePull();
}
private function abortPull($message, Exception $ex = null) {
$code_error = PhabricatorRepositoryStatusMessage::CODE_ERROR;
$this->updateRepositoryInitStatus($code_error, $message);
if ($ex) {
throw $ex;
} else {
throw new Exception($message);
}
}
private function logPull($message) {
$code_working = PhabricatorRepositoryStatusMessage::CODE_WORKING;
$this->updateRepositoryInitStatus($code_working, $message);
$this->log('%s', $message);
}
private function donePull() {
$code_okay = PhabricatorRepositoryStatusMessage::CODE_OKAY;
$this->updateRepositoryInitStatus($code_okay);
}
private function updateRepositoryInitStatus($code, $message = null) {
$this->getRepository()->writeStatusMessage(
PhabricatorRepositoryStatusMessage::TYPE_INIT,
$code,
array(
'message' => $message
));
}
private function installHook($path) {
$this->log('%s', pht('Installing commit hook to "%s"...', $path));
$repository = $this->getRepository();
$callsign = $repository->getCallsign();
$root = dirname(phutil_get_library_root('phabricator'));
$bin = $root.'/bin/commit-hook';
$full_php_path = Filesystem::resolveBinary('php');
$cmd = csprintf(
'exec %s -f %s -- %s "$@"',
$full_php_path,
$bin,
$callsign);
$hook = "#!/bin/sh\n{$cmd}\n";
Filesystem::writeFile($path, $hook);
Filesystem::changePermissions($path, 0755);
}
private function installHookDirectory($path) {
$readme = pht(
"To add custom hook scripts to this repository, add them to this ".
"directory.\n\nPhabricator will run any executables in this directory ".
"after running its own checks, as though they were normal hook ".
"scripts.");
Filesystem::createDirectory($path, 0755);
Filesystem::writeFile($path.'/README', $readme);
}
/* -( Pulling Git Working Copies )----------------------------------------- */
/**
* @task git
*/
private function executeGitCreate() {
$repository = $this->getRepository();
$path = rtrim($repository->getLocalPath(), '/');
if ($repository->isHosted()) {
$repository->execxRemoteCommand(
'init --bare -- %s',
$path);
} else {
$repository->execxRemoteCommand(
'clone --bare -- %P %s',
$repository->getRemoteURIEnvelope(),
$path);
}
}
/**
* @task git
*/
private function executeGitUpdate() {
$repository = $this->getRepository();
list($err, $stdout) = $repository->execLocalCommand(
'rev-parse --show-toplevel');
$message = null;
$path = $repository->getLocalPath();
if ($err) {
// Try to raise a more tailored error message in the more common case
// of the user creating an empty directory. (We could try to remove it,
// but might not be able to, and it's much simpler to raise a good
// message than try to navigate those waters.)
if (is_dir($path)) {
$files = Filesystem::listDirectory($path, $include_hidden = true);
if (!$files) {
$message =
"Expected to find a git repository at '{$path}', but there ".
"is an empty directory there. Remove the directory: the daemon ".
"will run 'git clone' for you.";
} else {
$message =
"Expected to find a git repository at '{$path}', but there is ".
"a non-repository directory (with other stuff in it) there. Move ".
"or remove this directory (or reconfigure the repository to use a ".
"different directory), and then either clone a repository ".
"yourself or let the daemon do it.";
}
} else if (is_file($path)) {
$message =
"Expected to find a git repository at '{$path}', but there is a ".
"file there instead. Remove it and let the daemon clone a ".
"repository for you.";
} else {
$message =
"Expected to find a git repository at '{$path}', but did not.";
}
} else {
$repo_path = rtrim($stdout, "\n");
if (empty($repo_path)) {
// This can mean one of two things: we're in a bare repository, or
// we're inside a git repository inside another git repository. Since
// the first is dramatically more likely now that we perform bare
// clones and I don't have a great way to test for the latter, assume
// we're OK.
} else if (!Filesystem::pathsAreEquivalent($repo_path, $path)) {
$err = true;
$message =
"Expected to find repo at '{$path}', but the actual ".
"git repository root for this directory is '{$repo_path}'. ".
"Something is misconfigured. The repository's 'Local Path' should ".
"be set to some place where the daemon can check out a working ".
"copy, and should not be inside another git repository.";
}
}
if ($err && $repository->canDestroyWorkingCopy()) {
phlog("Repository working copy at '{$path}' failed sanity check; ".
"destroying and re-cloning. {$message}");
Filesystem::remove($path);
$this->executeGitCreate();
} else if ($err) {
throw new Exception($message);
}
$retry = false;
do {
// This is a local command, but needs credentials.
if ($repository->isWorkingCopyBare()) {
// For bare working copies, we need this magic incantation.
$future = $repository->getRemoteCommandFuture(
'fetch origin %s --prune',
'+refs/heads/*:refs/heads/*');
} else {
$future = $repository->getRemoteCommandFuture(
'fetch --all --prune');
}
$future->setCWD($path);
list($err, $stdout, $stderr) = $future->resolve();
if ($err && !$retry && $repository->canDestroyWorkingCopy()) {
$retry = true;
// Fix remote origin url if it doesn't match our configuration
$origin_url = $repository->execLocalCommand(
'config --get remote.origin.url');
$remote_uri = $repository->getRemoteURIEnvelope();
if ($origin_url != $remote_uri->openEnvelope()) {
$repository->execLocalCommand(
'remote set-url origin %P',
$remote_uri);
}
} else if ($err) {
throw new Exception(
"git fetch failed with error #{$err}:\n".
"stdout:{$stdout}\n\n".
"stderr:{$stderr}\n");
} else {
$retry = false;
}
} while ($retry);
}
/**
* @task git
*/
private function installGitHook() {
$repository = $this->getRepository();
$root = $repository->getLocalPath();
if ($repository->isWorkingCopyBare()) {
$path = '/hooks/pre-receive';
} else {
$path = '/.git/hooks/pre-receive';
}
$this->installHook($root.$path);
}
/* -( Pulling Mercurial Working Copies )----------------------------------- */
/**
* @task hg
*/
private function executeMercurialCreate() {
$repository = $this->getRepository();
$path = rtrim($repository->getLocalPath(), '/');
if ($repository->isHosted()) {
$repository->execxRemoteCommand(
'init -- %s',
$path);
} else {
$repository->execxRemoteCommand(
'clone --noupdate -- %P %s',
$repository->getRemoteURIEnvelope(),
$path);
}
}
/**
* @task hg
*/
private function executeMercurialUpdate() {
$repository = $this->getRepository();
$path = $repository->getLocalPath();
// This is a local command, but needs credentials.
$future = $repository->getRemoteCommandFuture('pull -u');
$future->setCWD($path);
try {
$future->resolvex();
} catch (CommandException $ex) {
$err = $ex->getError();
$stdout = $ex->getStdOut();
// NOTE: Between versions 2.1 and 2.1.1, Mercurial changed the behavior
// of "hg pull" to return 1 in case of a successful pull with no changes.
// This behavior has been reverted, but users who updated between Feb 1,
// 2012 and Mar 1, 2012 will have the erroring version. Do a dumb test
// against stdout to check for this possibility.
- // See: https://github.com/facebook/phabricator/issues/101/
+ // See: https://github.com/phacility/phabricator/issues/101/
// NOTE: Mercurial has translated versions, which translate this error
// string. In a translated version, the string will be something else,
// like "aucun changement trouve". There didn't seem to be an easy way
// to handle this (there are hard ways but this is not a common problem
// and only creates log spam, not application failures). Assume English.
// TODO: Remove this once we're far enough in the future that deployment
// of 2.1 is exceedingly rare?
if ($err == 1 && preg_match('/no changes found/', $stdout)) {
return;
} else {
throw $ex;
}
}
}
/**
* @task hg
*/
private function installMercurialHook() {
$repository = $this->getRepository();
$path = $repository->getLocalPath().'/.hg/hgrc';
$root = dirname(phutil_get_library_root('phabricator'));
$bin = $root.'/bin/commit-hook';
$data = array();
$data[] = '[hooks]';
// This hook handles normal pushes.
$data[] = csprintf(
'pretxnchangegroup.phabricator = %s %s %s',
$bin,
$repository->getCallsign(),
'pretxnchangegroup');
// This one handles creating bookmarks.
$data[] = csprintf(
'prepushkey.phabricator = %s %s %s',
$bin,
$repository->getCallsign(),
'prepushkey');
$data[] = null;
$data = implode("\n", $data);
$this->log('%s', pht('Installing commit hook config to "%s"...', $path));
Filesystem::writeFile($path, $data);
}
/* -( Pulling Subversion Working Copies )---------------------------------- */
/**
* @task svn
*/
private function executeSubversionCreate() {
$repository = $this->getRepository();
$path = rtrim($repository->getLocalPath(), '/');
execx('svnadmin create -- %s', $path);
}
/**
* @task svn
*/
private function installSubversionHook() {
$repository = $this->getRepository();
$root = $repository->getLocalPath();
$path = '/hooks/pre-commit';
$this->installHook($root.$path);
}
}
diff --git a/src/docs/user/feedback.diviner b/src/docs/user/feedback.diviner
index 216482030d..bfb395be2b 100644
--- a/src/docs/user/feedback.diviner
+++ b/src/docs/user/feedback.diviner
@@ -1,149 +1,149 @@
@title Give Feedback! Get Support!
@short Feedback/Support
@group intro
How to give us feedback, report bugs, and request features, and get support for
problems with Phabricator.
= Overview =
We'd love to hear your feedback about Phabricator, whether it's good or bad. We
stay on top of bug reports and fix many of them within a day or two (and
sometimes within hours). The Phabricator roadmap is determined in large part by
user feedback and feature requests. Your feedback matters, will often have an
immediate short-term impact, and the project leads are actively listening to it.
We also try to provide a very high level of free support. If you have trouble
with anything or just don't understand how something works, ask us! We're happy
to help, and it's usually valuable for us because we can prevent the problem
in the code (or document it better) so future users don't hit it.
Some day we will no doubt grow callous and distant, but for now the community
is small enough that we can provide a high level of service and support to
everyone and still have plenty of time to write code.
If you're in the SF bay area, we're also happy to come onsite and help you set
things up, answer any questions you might have, or just hang out and tell
Facebook war stories.
The best ways to provide feedback are:
= Maniphest =
The best way to report bugs and request features is through
[[http://secure.phabricator.com/maniphest/task/create/ | Maniphest]]. Just file
the bug/request and we'll handle everything else. (If it's time-sensitive or
blocking you, feel free to assign it to `epriestley`.) Feel free to file support
requests, general questions, or random feedback this way, too.
= GitHub Issues =
You can also use
-[[https://github.com/facebook/phabricator/issues/new | GitHub Issues]] if you
+[[https://github.com/phacility/phabricator/issues/new | GitHub Issues]] if you
prefer.
= IRC =
We're active in #phabricator on FreeNode, and it's the best place to ask
questions and get support.
= Email =
You can email us at `btrahan@phacility.com` and `epriestley@phacility.com`.
= Filing Good Feature Requests =
When filing a feature request, please provide as much information as possible,
especially about what your use case is and why you want the feature. Explaining
what your larger goals are is very helpful, and lets us design better features.
Tell us what your problem is before you tell us your idea to solve it: sometimes
we can come up with a better approach to the problem, a slightly different
approach that solves more problems or helps other users, or a way to make the
problem go away entirely.
= Filing Good Bug Reports =
When filing a bug report, please provide as much information as possible. In
particular:
- If you received an error message, please please please provide it! It is
often incredibly useful. See @{article:Please Please Please}.
- The second most useful thing to us is reproduction steps. If at all
possible, provide a brief list of steps required to reproduce the problem.
- If something you didn't expect (other than a crash or obvious error)
happened, tell us what you expected and what actually happened.
We can fix clearly-described bugs with reproduction steps and error messages
much more quickly than vague bugs we can't reproduce.
In particular, if you don't include error messages, we need to ask you for error
messages. We will nearly always need to do this, and nearly always be unable
to continue until you provide them. You'll save everyone time if you spend a
few extra seconds copy/pasting them in the first place.
Generally, err on the side of giving us too much information. It's much quicker
and easier for us to filter out information that isn't relevant than it is to
go back and forth asking you to provide more details.
Tips:
- For issues with `arc`, you can get more information by running the command
with the `--trace` flag. For instance, run `arc diff --trace` instead of
`arc diff`. Including this output in your bug report is often helpful.
- For issues with Phabricator, check your webserver error logs for more
information. For Apache, this is usually `/var/log/httpd/error.log` or
`/var/log/apache2/error.log`.
- For issues with the UI, check your Javascript error console in your browser.
- Some other things, like daemons, have debug flags or troubleshooting steps
covered in their documentation. Enabling these flags may give you more
information about the problem.
= Unreproducible Problems =
Before we can fix a bug, we need to reproduce it. If we can't reproduce a
problem, we can't tell if we've fixed it and often won't be able to figure out
why it is occurring.
Most problems reproduce easily, but some are more difficult to reproduce. We
will generally make a reasonable effort to reproduce problems, but sometimes
we will be unable to reproduce an issue.
Many of these unreproducible issues turn out to be bizarre environmental
problems that are unique to one user's install, and figuring out what is wrong
takes a very long time with a lot of back and forth as we ask questions to
narrow down the cause of the problem. When we eventually figure it out and fix
it, few others benefit (in some cases, no one else). This sort of fishing
expedition is not a good use of anyone's time, and it's very hard for us to
prioritize solving these problems because they represent a huge effort for very
little benefit. These problems are a tiny fraction of requests (maybe 1-2%) but
take up the vast majority of our support effort (maybe 80%).
**If you want us to fix a bug we can't reproduce, you need to build us a working
reproduction case.** Generally, this means a `root` login on a machine where the
issue occurs. For example:
- Bring up a new machine (e.g., in EC2), install Phabricator on it, configure
it so the problem is reproducible, and then give us access to it.
- If the machine Phabricator is running on is nonessential/nonsensitive and
you're comfortable with us having root on it, give us credentials.
- If the issue is with Git, SVN or Mercurial, create a new empty repository,
add a commit or series of commits which replicate the issue, and give us
a zip/tarball of the repository as a reproduction case.
- If you're in the San Francisco bay area, we can probably swing by and fix
the issue onsite.
These are all fairly heavyweight and will take some time, but often //less//
of your time than a fishing expedition. If you can build a reproduction case,
there is a very high chance we can resolve your problem quickly.
Alternatively, you can pay us an enormous pile of money for some kind of
enterprise support thing and we'd be thrilled to go fishing with you for as long
as you remain solvent. Email us (see above) for specifics.
= Next Steps =
Continue by:
- Filing a bug of feature request in
[[http://secure.phabricator.com/maniphest/task/create/ | Maniphest]]; or
- contributing to Phabricator with @{article:Contributor Introduction}.
diff --git a/src/docs/user/installation_guide.diviner b/src/docs/user/installation_guide.diviner
index ece216513b..b829c5aa1f 100644
--- a/src/docs/user/installation_guide.diviner
+++ b/src/docs/user/installation_guide.diviner
@@ -1,173 +1,173 @@
@title Installation Guide
@group intro
This document contains basic install instructions to get Phabricator up and
running.
= Installation Requirements =
You will need **a computer**. Options include:
- **A Normal Computer**: This is strongly recommended. Many installs use a VM
in EC2. Phabricator installs properly and works well on a normal computer.
- **A Shared Host**: This may work, but is not recommended. Many shared
hosting environments have restrictions which prevent some of Phabricator's
features from working. Consider using a normal computer instead.
- **A SAN Appliance, Network Router, Gaming Console, Raspberry Pi, etc.**:
Although you may be able to install Phabricator on specialized hardware, it
is unlikely to work well and will be difficult for us to support. Strongly
consider using a normal computer instead.
- **A Toaster, Car, Firearm, Thermostat, etc.**: Yes, many modern devices now
have embedded computing capability. We live in interesting times. However,
you should not install Phabricator on these devices. Instead, install it on
a normal computer.
To install the Phabricator server software, you will need an **operating
system** on your normal computer which is **not Windows**. Note that **the
command line interface //does// work on Windows**, and **you can //use//
Phabricator from any operating system with a web browser**. However, the server
software does not run on Windows. It does run on most other operating systems,
so choose one of these instead:
- **Linux**: Most installs use Linux.
- **Mac OS X**: Mac OS X is an acceptable flavor of Linux.
- **FreeBSD**: While FreeBSD is certainly not a flavor of Linux, it is a fine
operating system possessed of many desirable qualities, and Phabricator will
install and run properly on FreeBSD.
- **Solaris, etc.**: Other systems which look like Linux and quack like Linux
will generally work fine, although we may suffer a reduced ability to
support and resolve issues on unusual operating systems.
Beyond an operating system, you will need **a webserver**.
- **Apache**: Many installs use Apache + `mod_php`.
- **nginx**: Many installs use nginx + `php-fpm`.
- **lighttpd**: `lighttpd` is less popular than Apache or nginx, but it
works fine.
- **Other**: Other webservers which can run PHP are also likely to work fine,
although these installation instructions will not cover how to set them up.
- **PHP Builtin Server**: You can use the builtin PHP webserver for
development or testing, although it should not be used in production.
You will also need:
- **MySQL**: You need MySQL.
- **PHP**: You need PHP 5.2 or newer.
You'll probably also need a **domain name**. In particular, you should read this
note:
NOTE: Phabricator must be installed on an entire domain. You can not install it
to a path on an existing domain, like `example.com/phabricator/`. Instead,
install it to an entire domain or subdomain, like `phabricator.example.com`.
= Installing Required Components =
If you are installing on Ubuntu or an RedHat derivative, there are install
scripts available which should handle most of the things discussed in this
document for you:
- **RedHat Derivatives**:
<http://www.phabricator.com/rsrc/install/install_rhel-derivs.sh>
- **Ubuntu**: <http://www.phabricator.com/rsrc/install/install_ubuntu.sh>
If those work for you, you can skip directly to the
@{article:Configuration Guide}. These scripts are also available in the
##scripts/install## directory in the project itself.
Otherwise, here's a general description of what you need to install:
- git (usually called "git" in package management systems)
- Apache (usually "httpd" or "apache2") (or nginx)
- MySQL Server (usually "mysqld" or "mysql-server")
- PHP (usually "php")
- Required PHP extensions: mbstring, iconv, mysql (or mysqli), curl, pcntl
(these might be something like "php-mysql" or "php5-mysql")
- Optional PHP extensions: gd, apc (special instructions for APC are available
below if you have difficulty installing it), xhprof (instructions below,
you only need this if you are developing Phabricator)
If you already have LAMP setup, you've probably already got everything you need.
It may also be helpful to refer to the install scripts above, even if they don't
work for your system.
Now that you have all that stuff installed, grab Phabricator and its
dependencies:
$ cd somewhere/ # pick some install directory
- somewhere/ $ git clone git://github.com/facebook/libphutil.git
- somewhere/ $ git clone git://github.com/facebook/arcanist.git
- somewhere/ $ git clone git://github.com/facebook/phabricator.git
+ somewhere/ $ git clone git://github.com/phacility/libphutil.git
+ somewhere/ $ git clone git://github.com/phacility/arcanist.git
+ somewhere/ $ git clone git://github.com/phacility/phabricator.git
= Installing APC (Optional) =
Like everything else written in PHP, Phabricator will run much faster with APC
installed. You likely need to install "pcre-devel" first:
sudo yum install pcre-devel
Then you have two options. Either install via PECL (try this first):
sudo yum install php-pear
sudo pecl install apc
**If that doesn't work**, grab the package from PECL directly and follow the
build instructions there:
http://pecl.php.net/package/APC
Installing APC is optional but **strongly recommended**, especially on
production hosts.
Once APC is installed, test that it is available by running:
php -i | grep apc
If it doesn't show up, add:
extension=apc.so
..to "/etc/php.d/apc.ini" or the "php.ini" file indicated by "php -i".
= Installing XHProf (Optional) =
XHProf is a PHP profiling tool. You don't need to install it unless you are
developing Phabricator and making performance changes.
You can install xhprof with:
$ pecl install xhprof
If you have a PEAR version prior to 1.9.3, you may run into a `phpize` failure.
If so, you can download the source and build it with:
$ cd extension/
$ phpize
$ ./configure
$ make
$ sudo make install
You may also need to add "##extension=xhprof.so##" to your php.ini.
See <https://bugs.php.net/bug.php?id=59747> for more information.
= Updating Phabricator =
Since Phabricator is under active development, you should update frequently. To
update Phabricator:
- Stop the webserver (including `php-fpm`, if you use it).
- Run `git pull` in `libphutil/`, `arcanist/` and `phabricator/`.
- Run `phabricator/bin/storage upgrade`.
- Restart the webserver (and `php-fpm`, if you stopped it earlier).
For more details, see @{article:Configuration Guide}. You can use a script
similar to this one to automate the process:
http://www.phabricator.com/rsrc/install/update_phabricator.sh
= Next Steps =
Continue by:
- configuring Phabricator with the @{article:Configuration Guide}.
diff --git a/src/docs/user/userguide/arcanist.diviner b/src/docs/user/userguide/arcanist.diviner
index b9c497007c..5211e173d8 100644
--- a/src/docs/user/userguide/arcanist.diviner
+++ b/src/docs/user/userguide/arcanist.diviner
@@ -1,185 +1,185 @@
@title Arcanist User Guide
@group userguide
Guide to Arcanist, a command-line interface to Phabricator.
Arcanists provides command-line access to many Phabricator tools (like
Differential, Files, and Paste), integrates with static analysis ("lint") and
unit tests, and manages common workflows like getting changes into Differential
for review.
A detailed command reference is available by running ##arc help##. This
document provides an overview of common workflows and installation.
Arcanist has technical, contributor-focused documentation here:
<http://www.phabricator.com/docs/arcanist/>
= Quick Start =
A quick start guide is available at @{article:Arcanist Quick Start}. It provides
a much more compact summary of how to get `arc` set up and running for a new
project. You may want to start there, and return here if you need more
information.
= Overview =
Arcanist is a wrapper script that sits on top of other tools (e.g.,
Differential, linters, unit test frameworks, git, Mercurial, and SVN) and
provides a simple command-line API to manage code review and some related
revision control operations.
For a detailed list of all available commands, run:
$ arc help
For detailed information about a specific command, run:
$ arc help <command>
Arcanist allows you to do things like:
- get detailed help about available commands with ##arc help##
- send your code to Differential for review with ##arc diff## (for detailed
instructions, see @{article:Arcanist User Guide: arc diff})
- show pending revision information with ##arc list##
- find likely reviewers for a change with ##arc cover##
- apply changes in a revision to the working copy with ##arc patch##
- download a patch from Differential with ##arc export##
- update Git commit messages after review with ##arc amend##
- commit SVN changes with ##arc commit##
- push Git and Mercurial changes with ##arc land##
- view enhanced information about Git branches with ##arc branch##
Once you've configured lint and unit test integration, you can also:
- check your code for syntax and style errors with ##arc lint##
(see @{article:Arcanist User Guide: Lint})
- run unit tests that cover your changes with ##arc unit##
Arcanist integrates with other tools:
- upload and download files with ##arc upload## and ##arc download##
- create and view pastes with ##arc paste##
Arcanist has some advanced features as well, you can:
- execute Conduit method calls with ##arc call-conduit##
- create or update libphutil libraries with ##arc liberate##
- activate tab completion with ##arc shell-complete##
- install arc as a pre-commit hook with ##arc svn-hook-pre-commit## or
##arc git-hook-pre-receive##
- ...or extend Arcanist and add new commands.
Except where otherwise noted, these workflows are generally agnostic to the
underlying version control system and will work properly in git, Mercurial, or
SVN repositories.
= Installing Arcanist =
Arcanist is meant to be installed on your local machine or development server --
whatever machine you're editing code on. It runs on:
- Linux;
- Other operating systems which are pretty similar to Linux, or which
Linux is pretty similar to;
- FreeBSD, a fine operating system held in great esteem by many;
- Mac OS X (see @{article:Arcanist User Guide: Mac OS X}); and
- Windows (see @{article:Arcanist User Guide: Windows}).
Arcanist is written in PHP, so you need to install the PHP CLI first if you
don't already have it. Arcanist should run on PHP 5.2 and newer. If you don't
have PHP installed, you can download it from <http://www.php.net/>.
To install Arcanist, pick an install directory and clone the code from GitHub:
- some_install_path/ $ git clone git://github.com/facebook/libphutil.git
- some_install_path/ $ git clone git://github.com/facebook/arcanist.git
+ some_install_path/ $ git clone git://github.com/phacility/libphutil.git
+ some_install_path/ $ git clone git://github.com/phacility/arcanist.git
This should leave you with a directory structure like this
some_install_path/ # Wherever you chose to install it.
arcanist/ # Arcanist-specific code and libraries.
libphutil/ # A shared library Arcanist depends upon.
Now add ##some_install_path/arcanist/bin/## to your PATH environment variable.
When you type "arc", you should see something like this:
Usage Exception: No command provided. Try 'arc help'.
If you get that far, you've done things correctly. If you get an error or have
trouble getting this far, see these detailed guides:
- On Windows: @{article:Arcanist User Guide: Windows}
- On Mac OS X: @{article:Arcanist User Guide: Mac OS X}
You can later upgrade Arcanist and libphutil to the latest versions with
`arc upgrade`:
$ arc upgrade
== Installing Arcanist for a Team ==
Arcanist changes quickly, so it can be something of a headache to get it
installed and keep people up to date. Here are some approaches you might be
able to use:
- Facebook does most development on development servers, which have a standard
environment and NFS mounts. Arcanist and libphutil themselves live on an
NFS mount, and the default `.bashrc` adds them to the PATH. Updating the
mount source updates everyone's versions, and new employees have a working
`arc` when they first log in.
- Another common approach is to write an install script as an action into
existing build scripts, so users can run `make install-arc` or
`ant install-arc` or similar.
- In general, if this sucks and is causing you pain, let us know (see
@{article:Give Feedback! Get Support!}). We're planning to improve this at
some point, but it's somewhat complicated to get right. While it can take a
little time to set up, we aren't getting feedback that it's a persistent
pain point, so it hasn't been a priority.
== Installing Tab Completion ==
If you use ##bash##, you can set up tab completion by adding something like this
to your ##.bashrc##, ##.profile## or similar:
source /path/to/arcanist/resources/shell/bash-completion
== Configuration ==
Some Arcanist commands can be configured. This configuration is read from
several sources:
# A customization can force any setting with
@{method@arcanist:ArcanistWorkingCopyIdentity::setRuntimeConfig}.
# User can specify settings for working copy in `arc/config` file located in
VCS directory (e.g. `.git/arc/config`) in JSON format. This file can also be
modified by running `arc set-config --local`.
# Repository can specify its config in `.arcconfig` in JSON format.
# User can specify the settings in `~/.arcrc` (JSON) through the `config` key.
This file can be modified also by `arc set-config --global`.
# Machine can specify the settings with `/etc/arcconfig` (JSON). On Windows,
the file path is 'C:\ProgramData\Phabricator\Arcanist\config`.
The first place where the setting is defined wins.
Existing settings can be printed with `arc get-config`.
== Next Steps ==
Continue by:
- setting up a new project for use with `arc`, with
@{article:Arcanist User Guide: Configuring a New Project}; or
- learning how to use `arc` to send changes for review with
@{article:Arcanist User Guide: arc diff}.
Advanced topics are also available. These are detailed guides to configuring
technical features of `arc` that refine its behavior. You do not need to read
them to get it working.
- @{article:Arcanist User Guide: Commit Ranges}
- @{article:Arcanist User Guide: Lint}
- @{article:Arcanist User Guide: Customizing Existing Linters}
- @{article:Arcanist User Guide: Customizing Lint, Unit Tests and Workflows}
- @{article:Arcanist User Guide: Code Coverage}
- @{article:Arcanist User Guide: Repository Hooks}
diff --git a/src/docs/user/userguide/arcanist_quick_start.diviner b/src/docs/user/userguide/arcanist_quick_start.diviner
index 141416d301..3d4407f42a 100644
--- a/src/docs/user/userguide/arcanist_quick_start.diviner
+++ b/src/docs/user/userguide/arcanist_quick_start.diviner
@@ -1,86 +1,86 @@
@title Arcanist Quick Start
@group userguide
Quick guide to getting Arcanist working for a new project.
This is a summary of steps to install Arcanist, configure a project for use with
it, and run `arc` to send changes for review.
= Install Arcanist =
For detailed instructions on installing Arcanist, see
@{article:Arcanist User Guide}.
- For Mac OS X, see @{article:Arcanist User Guide: Mac OS X}.
- For Windows, see @{article:Arcanist User Guide: Windows}.
First, install dependencies:
- Install PHP.
- Install Git.
Then install Arcanist itself:
$ mkdir somewhere/
$ cd somewhere/
- somewhere/ $ git clone git://github.com/facebook/libphutil.git
- somewhere/ $ git clone git://github.com/facebook/arcanist.git
+ somewhere/ $ git clone git://github.com/phacility/libphutil.git
+ somewhere/ $ git clone git://github.com/phacility/arcanist.git
Add `arc` to your path:
$ export PATH="$PATH:/somewhere/arcanist/bin/"
This won't work for Windows, see @{article:Arcanist User Guide: Windows} for
instructions.
= Configure Your Project =
For detailed instructions on project configuration, see
@{article:Arcanist User Guide: Configuring a New Project}.
Create a `.arcconfig` file in your project's working copy:
$ cd yourproject/
yourproject/ $ $EDITOR .arcconfig
yourproject/ $ cat .arcconfig
{
"project_id" : "yourprojectname",
"conduit_uri" : "https://phabricator.example.com/"
}
Set `project_id` to a string that identifies the project.
Set `conduit_uri` to the URI for your Phabricator install (where `arc`
should send changes to).
NOTE: You should **commit this file** to the repository.
= Install Arcanist Credentials =
Credentials allow you to authenticate. You must have an account on Phabricator
before you can perform this step.
$ cd yourproject/
yourproject/ $ arc install-certificate
...
Follow the instructions. This will link your user account on your local machine
to your Phabricator account.
= Send Changes For Review =
For detailed instructions on using `arc diff`, see
@{article:Arcanist User Guide: arc diff}.
$ $EDITOR file.c
$ arc diff
= Next Steps =
Continue by:
- learning more about project configuration with
@{article:Arcanist User Guide: Configuring a New Project}; or
- learning more about `arc diff` with
@{article:Arcanist User Guide: arc diff}; or
- returning to @{article:Arcanist User Guide}.
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Jan 19 2025, 21:35 (6 w, 1 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1129005
Default Alt Text
(48 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment