나는 이것이 계속해서 궁금했고 아직 어디에서도 내 대답을 찾지 못했습니다. 업그레이드 명령 후에 몇몇 소스가 -y를 던지는 이유를 설명할 수 있는 사람이 있습니까? 그 기능은 무엇입니까?
답변1
apt-get update
저장소에서 패키지 목록을 다운로드하고 "업데이트"하여 최신 버전의 패키지 및 해당 종속성에 대한 정보를 얻습니다. 모든 저장소와 PPA에 대해 이 작업을 수행합니다.에서https://linux.die.net/man/8/apt-get
Used to re-synchronize the package index files from their sources. The indexes of available packages are fetched from the location(s) specified in /etc/apt/sources.list(5). An update should always be performed before an upgrade or dist-upgrade.
apt-get upgrade
APT가 apt-get 업데이트를 통해 이러한 새 버전에 대해 알고 있는 경우 시스템에 존재하는 패키지의 새 버전을 가져옵니다.에서https://linux.die.net/man/8/apt-get
Used to install the newest versions of all packages currently installed on the system from the sources enumerated in /etc/apt/sources.list(5). Packages currently installed with new versions available are retrieved and upgraded; under no circumstances are currently installed packages removed, nor are packages that are not already installed retrieved and installed. New versions of currently installed packages that cannot be upgraded without changing the install status of another package will be left at their current version. An update must be performed first so that apt-get knows that new versions of packages are available.
-y, --yes, --assume-yes
Automatic yes to prompts; assume "yes" as answer to all prompts and run non-interactively. If an undesirable situation, such as changing a held package, trying to install a unauthenticated package or removing an essential package occurs then apt-get will abort. Configuration Item: APT::Get::Assume-Yes.
apt-get
옵션 과 함께 사용하지 않기로 선택한 경우-y
명령 실행을 계속하려면 해당 명령에서 표시되는 모든 프롬프트에 대화식으로 응답해야 합니다.