Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions source/installation/index.rst
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
############
Installation
インストール
############

CodeIgniter4 can be installed in a number of different ways: manually,
using `Composer <https://getcomposer.org>`_, or using
`Git <https://git-scm.com/>`_.
Which is right for you?
CodeIgniter4 は様々な方法でインストールできます。
`Composer <https://getcomposer.org>`_ を使うこともできますし、
`Git <https://git-scm.com/>`_ を使うこともできますね!
どちらがあなたにぴったりですか?

- If you would like the simple "download & go" install that CodeIgniter3
is known for, choose the manual installation.
- If you plan to add third party packages to your project, or want to keep
CodeIgniter up to date easily, we recommend the Composer installation.
- 簡単に "ダウンロードして実行" をしたい場合はCodeIgniter3と同様に、
手動インストールを選択します。
- サードパーティ製のパッケージをプロジェクトに追加する予定がある場合は
CodeIgniter が簡単に最新の状態になるように、composer インストールをお勧めします。

.. toctree::
:titlesonly:
Expand All @@ -22,11 +22,11 @@ Which is right for you?
troubleshooting
repositories

However you choose to install and run CodeIgniter4, the
`user guide <https://codeigniter4.github.io/userguide/>`_ is accessible online.
CodeIgniter4をインストールして実行する場合、
`ユーザーガイド <https://codeigniter4.github.io/userguide/>`_ にはオンラインでアクセスすることができます。

.. note:: Before using CodeIgniter 4, make sure that your server meets the
:doc:`requirements </intro/requirements>`, in particular the PHP
version and the PHP extensions that are needed.
You may find that you have to uncomment the ``php.ini`` "extension"
lines to enable "curl" and "intl", for instance.
.. note:: CodeIgniter 4を使用する前にサーバー要件について確認をしてください。
特に、:doc:`requirements </intro/requirements>`
PHPのバージョンと必要なPHP拡張機能について確認しましょう。
``php.ini`` "extension" のコメントを解除する必要がある場合があります。
例えば "curl" "intl" を有効にする場合に必要です。
122 changes: 61 additions & 61 deletions source/installation/installing_composer.rst
Original file line number Diff line number Diff line change
@@ -1,111 +1,111 @@
Composer Installation
Composer インストール
###############################################################################

.. contents::
:local:
:depth: 1

Composer can be used in several ways to install CodeIgniter4 on your system.
CodeIgniter4ではcomposerを使ってインストールすることも可能です。

The first two techniques describe creating a skeleton project
using CodeIgniter4, that you would then use as the base for a new webapp.
The third technique described below lets you add CodeIgniter4 to an existing
最初に、
CodeIgniter4を使ってスケルトンプロジェクトを作成し、それをWebアプリのベースとして使用する方法を紹介します。
以下で説明する方法はCodeIgniter4 を既存のWebアプリに追加することができます。
webapp,

**Note**: if you are using a Git repository to store your code, or for
collaboration with others, then the ``vendor`` folder would normally
be "git ignored". In such a case, you will need to do a ``composer update``
when you clone the repository to a new system.
**Note**: Gitリポジトリを利用してコードを保存している場合、
また、他のユーザとのコラボレーションのために使用している場合は 通常 ``vendor``フォルダー以下の
ものは "git から無視" されます。このような場合には、
``composer update`` を利用する必要があります。

App Starter
アプリスターター
============================================================

The `CodeIgniter 4 app starter <https://github.com/codeigniter4/appstarter>`_
repository holds a skeleton application, with a composer dependency on
the latest released version of the framework.
`CodeIgniter 4 アプリスターター <https://github.com/codeigniter4/appstarter>`_
はスケルトンアプリケーションを保持しつつ、
composer が最新リリースのバージョンのものを取得します。

This installation technique would suit a developer who wishes to start
a new CodeIgniter4 based project.
このインストール方法は、
新しいCodeIgniter4ベースのプロジェクトを開始したい開発者に最適な方法です。

Installation & Set Up
インストールとセットアップ
-------------------------------------------------------

In the folder above your project root::
プロジェクトルート上のフォルダ :

composer create-project codeigniter4/appstarter project-root

The command above will create a "project-root" folder.
このコマンドは "project-root" フォルダーを作成し実行されます。

If you omit the "project-root" argument, the command will create an
"appstarter" folder, which can be renamed as appropriate.
"project-root" 引数を省略するとコマンドによって
"appstarter" フォルダが作成され、必要に応じて名前を変更することが可能です。

If you don't need or want phpunit installed, and all of its composer
dependencies, then add the "--no-dev" option to the end of the above
command line. That will result in only the framework, and the three
trusted dependencies that we bundle, being composer-installed.
phpunitとその全てのcomposer依存関係をインストールする必要がない場合、
またはインストールしたくない場合には上記のコマンドの最後に
"--no-dev" のオプションを追加します。その結果、フレームワークと、バンドルされている3つの信頼できる依存関係のみが作成されるかたちで
composer install が実行し終了します。

A sample such installation command, using the default project-root "appstarter"::
標準の プロジェクトルート "appstarter" が作成されるコマンドサンプル ::

composer create-project codeigniter4/appstarter --no-dev

After installation you should follow the steps in the "Upgrading" section.
インストール後 "アップグレード" の手順に従う必要があります。

Upgrading
アップグレード
-------------------------------------------------------

Whenever there is a new release, then from the command line in your project root::
新しいリリースがあるときは、プロジェクトルートからコマンドラインを実行します:

composer update

If you used the "--no-dev" option when you created the project, it
would be appropriate to do so here too, i.e. ``composer update --no-dev``.
"--no-dev" オプションを利用してインストールした場合には
``composer update --no-dev`` といったように、オプションをつけて実行しましょう。

Read the upgrade instructions, and check designated ``app/Config`` folders for affected changes.
アップグレード手順を読み、影響を受ける変更がないか、 ``app/Config`` フォルダーの中身を確認しましょう。

Pros
長所
-------------------------------------------------------

Simple installation; easy to update
とても簡単に、シンプルにアップデートができます。

Cons
短所
-------------------------------------------------------

You still need to check for ``app/Config`` changes after updating
更新後 ``app/Config`` の変更を確認する必要があります。

Structure
構造
-------------------------------------------------------

Folders in your project after set up:
セットアップ後のプロジェクト内のフォルダー:

- app, public, tests, writable
- app, public, tests, が書き込み可能かどうか
- vendor/codeigniter4/framework/system
- vendor/codeigniter4/framework/app & public (compare with yours after updating)
- vendor/codeigniter4/framework/app public (composer updateを使って更新したあとあなたのファイルと比較して確認してください)

Latest Dev
最新の開発
-------------------------------------------------------

The App Starter repo comes with a ``builds`` scripts to switch Composer sources between the
current stable release and the latest development branch of the framework. Use this script
for a developer who is willing to live with the latest unreleased changes, which may be unstable.
App Starter リポジトリは Composerソースを現在の安定板リリースとフレームワークの最新の開発ブランチで切り替えるための
``builds`` スクリプトが付属しています。このスクリプトは
不安定な可能性のある最新のみリリースの変更を喜んで受け入れる開発者のみが使用してください。

The `development user guide <https://codeigniter4.github.io/CodeIgniter4/>`_ is accessible online.
Note that this differs from the released user guide, and will pertain to the
develop branch explicitly.
この `開発版ユーザーガイド <https://codeigniter4.github.io/CodeIgniter4/>`_ はオンラインでアクセスできます。.
これはリリースされたユーザーガイドとは異なり、開発ブランチに明示的に関係すること
を注意してください。.

In your project root::
プロジェクトルート ::

php builds development

The command above will update **composer.json** to point to the ``develop`` branch of the
working repository, and update the corresponding paths in config and XML files. To revert
these changes run::
上記のコマンドは 作業リポジトリの ``develop`` を指すように **composer.json** を更新し、
configフィアルトXMLファイルの対応するパスを更新します。これらの変更を元に戻す場合
次のコマンドを実行します::

php builds release

After using the ``builds`` command be sure to run ``composer update`` to sync your vendor
folder with the latest target build.
``builds`` コマンドを実行した後、必ず ``composer update`` を実行して
vendor フォルダを最新のターゲットビルドと同期させてください。

Adding CodeIgniter4 to an Existing Project
既存のプロジェクトにCodeIgniter4を追加する
============================================================

The same `CodeIgniter 4 framework <https://github.com/codeigniter4/framework>`_
Expand All @@ -115,7 +115,7 @@ existing project using Composer.
Develop your app inside the ``app`` folder, and the ``public`` folder
will be your document root.

In your project root::
プロジェクトルート ::

composer require codeigniter4/framework

Expand All @@ -134,30 +134,30 @@ Copy the ``env``, ``phpunit.xml.dist`` and ``spark`` files, from
You will have to adjust the system path to refer to the vendor one, e.g. ``ROOTPATH . '/vendor/codeigniter4/framework/system'``,
- the ``$systemDirectory`` variable in ``app/Config/Paths.php``

Upgrading
アップグレード
-------------------------------------------------------

Whenever there is a new release, then from the command line in your project root::
新しいリリースがあるときは、プロジェクトルートからコマンドラインを実行します:

composer update

Read the upgrade instructions, and check designated
``app/Config`` folders for affected changes.

Pros
長所
-------------------------------------------------------

Relatively simple installation; easy to update

Cons
短所
-------------------------------------------------------

You still need to check for ``app/Config`` changes after updating
更新後 ``app/Config`` の変更を確認する必要があります。

Structure
構造
-------------------------------------------------------

Folders in your project after set up:
セットアップ後のプロジェクト内のフォルダー:

- app, public, tests, writable
- vendor/codeigniter4/framework/system
Expand Down