A history of all builds deployed to this environment

@return ArrayList
974736
public function DeployHistory() {
		$history = $this
			->Deployments()
			->sort('LastEdited DESC');
		$repo = $this->Project()->getRepository();
		if(!$repo) {
			return $history;
		}

		$ammendedHistory = new ArrayList();
		foreach($history as $deploy) {
			if(!$deploy->SHA) {
				continue;
			}
			try {
				$commit = $repo->getCommit($deploy->SHA);
				if($commit) {
					$deploy->Message = Convert::raw2xml($commit->getMessage());
				}
				// We can't find this SHA, so we ignore adding a commit message to the deployment
			} catch (Exception $ex) { }
			$ammendedHistory->push($deploy);
		}

		return $ammendedHistory;
	}
1010599
protected function getAllSourceFiles()
	{
		$files = array_merge(
			glob_recursive('build/*.php'),
			glob_recursive('src/*.php'),
			glob_recursive('tests/*.php'),
			glob('*.php')
		);

		sort($files);

		return $files;
	}
158561
public static function buildAll()
    {
        $result = [];
        foreach (static::$_types as $name => $type) {
            $result[$name] = isset(static::$_builtTypes[$name]) ? static::$_builtTypes[$name] : static::build($name);
        }

        return $result;
    }
913723
protected function buildIndex(): array
    {
        $path = $this->getStoragePath();
        if (!file_exists($path)) {
            return [];
        }

        if ($this->prefixed) {
            $list = $this->buildPrefixedIndexFromFilesystem($path);
        } else {
            $list = $this->buildIndexFromFilesystem($path);
        }

        ksort($list, SORT_NATURAL);

        return $list;
    }
174102
protected function buildIndex(): array
    {
        $file = $this->getFile($this->getStoragePath());
        $modified = $file->modified();

        $this->data = (array) $file->content();

        $list = [];
        foreach ($this->data as $key => $info) {
            $list[$key] = [
                'storage_key' => $key,
                'storage_timestamp' => $modified
            ];
        }

        return $list;
    }
131952
public function securityHistory()
    {
        $history = $this->wrappedObject->security()->get();

        $history->each(function ($item) {
            $item->security = true;
        });

        return $this->presenter->decorate($history);
    }
218145
public function getLastBuild()
    {
        if ($this->lastBuild == null) {
            $build = new self($this->getEngine(), $this->getProject());

            return $build;
        }

        return $this->lastBuild;
    }
68153
protected function getModelBuilds() {
        if (!$this->_modelBuilds) {
            $this->_modelBuilds = new ModelBuildList($this->version, $this->solution['sid']);
        }

        return $this->_modelBuilds;
    }
326996
public function getHistory(): array
    {
        $history = [];
        foreach ($this->xml->History->children() as $logEntry) {
            $log = [];
            foreach ($logEntry as $key => $val) {
                $log[lcfirst($key)] = (string) $val;
            }
            $history[] = $log;
        }

        return $history;
    }
550753
public function findAll()
    {
        if ($this->fileManager->isDir(Installer::BASE_PATH . self::HISTORY_PATH) === false) {
            throw new EnvironnementResolverException(
                sprintf(
                    'Unable to locate "%d"',
                    Installer::BASE_PATH . self::HISTORY_PATH
                )
            );
        }

        $historyCollection = new HistoryCollection();
        $searchPath        = Installer::BASE_PATH . self::HISTORY_PATH . '*' . self::FILE_EXTENSION;

        foreach ($this->fileManager->glob($searchPath) as $file) {
            $content = $this->fileManager->fileGetContent($file);

            try {
                $historyCollection->append($this->historyHydrator->jsonToDTO($content));
            } catch (InvalidHistoryException $e) {
                continue;
            }
        }

        return $historyCollection;
    }
53343
public RunList<R> newBuilds() {
        GregorianCalendar cal = new GregorianCalendar();
        cal.add(Calendar.DAY_OF_YEAR, -7);
        final long t = cal.getTimeInMillis();

        // can't publish on-going builds
        return filter(new Predicate<R>() {
            public boolean apply(R r) {
                return !r.isBuilding();
            }
        })
        // put at least 10 builds, but otherwise ignore old builds
        .limit(new CountingPredicate<R>() {
            public boolean apply(int index, R r) {
                return index < 10 || r.getTimeInMillis() >= t;
            }
        });
    }
731699
public function getAll()
    {
        $instances = array();
        $builder = new InstanceBuilder();

        foreach ($this->data as $className => $args) {
            if (class_exists($className)) {

                $instance = $builder->build($className, $args);
                array_push($instances, $instance);
            }
        }

        return $instances;
    }
413537
private List getVersions() {

        ArrayList ret = new ArrayList();

        int defaultHistoryVersions = OpenCms.getSystemInfo().getHistoryVersions();
        int historyVersions = 0;

        // Add the option for disabled version history
        ret.add(
            new CmsSelectWidgetOption(
                String.valueOf(-2),
                defaultHistoryVersions == -2,
                key(Messages.GUI_HISTORY_SETTINGS_VERSIONS_DISABLED_0)));

        // Iterate from 1 to 50 with a stepping of 1 for the first 10 entries and a stepping of five for the entries from 10 to 50
        while (historyVersions < 50) {

            // increment the history version
            historyVersions++;

            if (((historyVersions % 5) == 0) || (historyVersions <= 10)) {

                boolean defaultValue = defaultHistoryVersions == historyVersions;
                ret.add(
                    new CmsSelectWidgetOption(
                        String.valueOf(historyVersions),
                        defaultValue,
                        String.valueOf(historyVersions)));
            }
        }

        // If the default setting for the version history is more than 50
        if (defaultHistoryVersions > historyVersions) {
            ret.add(
                new CmsSelectWidgetOption(
                    String.valueOf(defaultHistoryVersions),
                    true,
                    String.valueOf(defaultHistoryVersions)));
        }

        // Add the option for unlimited version history
        ret.add(
            new CmsSelectWidgetOption(
                String.valueOf(-1),
                defaultHistoryVersions == -1,
                key(Messages.GUI_HISTORY_SETTINGS_VERSIONS_UNLIMITED_0)));

        return ret;
    }
560493
public function &GetFieldPkgShopWishlistMailHistoryList()
    {
        $oWishlistHistoryItems = $this->GetFromInternalCache('oPkgShopWishlistMailHistoryList');
        if (is_null($oWishlistHistoryItems)) {
            $oWishlistHistoryItems = TdbPkgShopWishlistMailHistoryList::GetListForPkgShopWishlistId($this->id, $this->iLanguageId);
            $oWishlistHistoryItems->bAllowItemCache = true;
            $this->SetInternalCache('oPkgShopWishlistMailHistoryList', $oWishlistHistoryItems);
        }

        return $oWishlistHistoryItems;
    }
1251813
public function index()
    {
        $this->layout->title = Lang::get('dashboard');
        $builds = $this->buildStore->getLatestBuilds(null, 10);

        foreach ($builds as &$build) {
            $build = BuildFactory::getBuild($build);
        }

        $this->view->display_branch = $this->config->get('phpci.latest_builds.show_branch', false);

        $this->view->builds   = $builds;
        $this->view->groups = $this->getGroupInfo();

        return $this->view->render();
    }
915376
protected function getUpdateList()
    {
        $start = [];
        $updates = update_get_update_list();
        foreach ($updates as $module => $update) {
            $start[$module] = $update['start'];
        }

        return $start;
    }
830204
public function getDiff()
    {
        $diff = [];

        foreach ($this->getUpdated() as $key) {
            $diff[$key]['old'] = $this->old($key);

            $diff[$key]['new'] = $this->new($key);
        }

        return $diff;
    }