/
githubmr
/
facebook-react
Обзор
Документация
Войти
/
githubmr
/
facebook-react
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
main
compiler/scripts/release/prompt-for-otp.js
24 строки
545 B
lauren
[compiler] Add missing copyrights (#33004)
24 апр 2025, 05:04
Не верифицирован
24 апр 2025, 05:04
ad09027
Код
Авторство
О чём код?
#!/usr/bin/env node /** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ const prompt = require('prompt-promise'); const run = async () => { while (true) { const otp = await prompt('NPM 2-factor auth code: '); prompt.done(); if (otp) { return otp; } else { console.error('\nTwo-factor auth is required to publish.'); // (Ask again.) } } }; module.exports = run;