comments and variable names
Summary: renaming across the app: - comments - variable names - constants Reviewed By: passy Differential Revision: D9861792 fbshipit-source-id: 72dea05d1427b1dc0f54a7865cc0ecffd69bdb27
This commit is contained in:
committed by
Facebook Github Bot
parent
df0a0da744
commit
e9490ca3b4
@@ -102,7 +102,7 @@ export default class AutoUpdateVersion extends Component<{}, State> {
|
||||
<span
|
||||
tabIndex={-1}
|
||||
role="button"
|
||||
title="Update available. Restart Sonar."
|
||||
title="Update available. Restart Flipper."
|
||||
onClick={remote.autoUpdater.quitAndInstall}>
|
||||
<Glyph color={colors.light30} name="breaking-news" />
|
||||
</span>
|
||||
|
||||
@@ -23,7 +23,7 @@ const {spawn} = require('child_process');
|
||||
const path = require('path');
|
||||
const {app, shell} = require('electron').remote;
|
||||
|
||||
const SONAR_PLUGIN_PATH = path.join(app.getPath('home'), '.flipper');
|
||||
const FLIPPER_PLUGIN_PATH = path.join(app.getPath('home'), '.flipper');
|
||||
const DYNAMIC_PLUGINS = JSON.parse(window.process.env.PLUGINS || '[]');
|
||||
|
||||
type NPMModule = {
|
||||
@@ -133,7 +133,7 @@ const getLatestVersion = (name: string): Promise<NPMModule> => {
|
||||
|
||||
const getPluginList = (): Promise<Array<NPMModule>> => {
|
||||
return fetch(
|
||||
'http://registry.npmjs.org/-/v1/search?text=keywords:sonar&size=250',
|
||||
'http://registry.npmjs.org/-/v1/search?text=keywords:flipper&size=250',
|
||||
)
|
||||
.then(res => res.json())
|
||||
.then(res => res.objects.map(o => o.package));
|
||||
@@ -161,7 +161,7 @@ class PluginItem extends PureComponent<
|
||||
const {name, status: initialStatus} = this.props.plugin;
|
||||
this.setState({working: true});
|
||||
const npm = spawn('npm', [action, name], {
|
||||
cwd: SONAR_PLUGIN_PATH,
|
||||
cwd: FLIPPER_PLUGIN_PATH,
|
||||
});
|
||||
|
||||
npm.stderr.on('data', e => {
|
||||
@@ -203,7 +203,7 @@ class PluginItem extends PureComponent<
|
||||
<FlexRow>
|
||||
{managed ? (
|
||||
<Text size="0.9em" color={colors.light30}>
|
||||
This plugin is not managed by Sonar, but loaded from{' '}
|
||||
This plugin is not managed by Flipper, but loaded from{' '}
|
||||
<Text size="1em" code={true}>
|
||||
{rootDir}
|
||||
</Text>
|
||||
@@ -255,7 +255,7 @@ class PluginManager extends PureComponent<Props, State> {
|
||||
plugins: DYNAMIC_PLUGINS.reduce((acc, plugin) => {
|
||||
acc[plugin.name] = {
|
||||
...plugin,
|
||||
managed: !(plugin.entry, '').startsWith(SONAR_PLUGIN_PATH),
|
||||
managed: !(plugin.entry, '').startsWith(FLIPPER_PLUGIN_PATH),
|
||||
status: 'installed',
|
||||
};
|
||||
return acc;
|
||||
|
||||
@@ -133,7 +133,7 @@ export default class WelcomeScreen extends PureComponent<Props, State> {
|
||||
onClick={() =>
|
||||
shell.openExternal('https://fbflipper.com/docs/understand.html')
|
||||
}>
|
||||
<Icon size={20} name="rocket" color={brandColors.Sonar} />
|
||||
<Icon size={20} name="rocket" color={brandColors.Flipper} />
|
||||
<FlexColumn>
|
||||
<ItemTitle>Using Flipper</ItemTitle>
|
||||
<ItemSubTitle>
|
||||
@@ -147,7 +147,7 @@ export default class WelcomeScreen extends PureComponent<Props, State> {
|
||||
'https://fbflipper.com/docs/create-plugin.html',
|
||||
)
|
||||
}>
|
||||
<Icon size={20} name="magic-wand" color={brandColors.Sonar} />
|
||||
<Icon size={20} name="magic-wand" color={brandColors.Flipper} />
|
||||
<FlexColumn>
|
||||
<ItemTitle>Create your own plugin</ItemTitle>
|
||||
<ItemSubTitle>Get started with these pointers</ItemSubTitle>
|
||||
@@ -159,7 +159,7 @@ export default class WelcomeScreen extends PureComponent<Props, State> {
|
||||
'https://fbflipper.com/docs/getting-started.html',
|
||||
)
|
||||
}>
|
||||
<Icon size={20} name="tools" color={brandColors.Sonar} />
|
||||
<Icon size={20} name="tools" color={brandColors.Flipper} />
|
||||
<FlexColumn>
|
||||
<ItemTitle>Add Flipper support to your app</ItemTitle>
|
||||
<ItemSubTitle>Get started with these pointers</ItemSubTitle>
|
||||
@@ -169,7 +169,7 @@ export default class WelcomeScreen extends PureComponent<Props, State> {
|
||||
onClick={() =>
|
||||
shell.openExternal('https://github.com/facebook/flipper/issues')
|
||||
}>
|
||||
<Icon size={20} name="posts" color={brandColors.Sonar} />
|
||||
<Icon size={20} name="posts" color={brandColors.Flipper} />
|
||||
<FlexColumn>
|
||||
<ItemTitle>Contributing and Feedback</ItemTitle>
|
||||
<ItemSubTitle>
|
||||
|
||||
@@ -54,7 +54,7 @@ type Actions<T> = AppendAndUpdateAction<T> | ResetAndUpdateAction<T>;
|
||||
* build by calling the `buildRow` function argument.
|
||||
*
|
||||
* An optional resetMethod argument can be provided which will replace the current rows with the
|
||||
* data provided. This is useful when connecting to sonar for this first time, or reconnecting to
|
||||
* data provided. This is useful when connecting to Flipper for this first time, or reconnecting to
|
||||
* the client in an unknown state.
|
||||
*/
|
||||
export function createTablePlugin<T: RowData>(props: Props<T>) {
|
||||
|
||||
@@ -86,7 +86,7 @@ export default (store: Store, logger: Logger) => {
|
||||
payload: new Set(deviceIDsToRemove),
|
||||
});
|
||||
console.error(
|
||||
'adb server shutdown. Run `adb start-server` and restart Sonar.',
|
||||
'adb server shutdown. Run `adb start-server` and restart Flipper.',
|
||||
);
|
||||
} else {
|
||||
throw err;
|
||||
|
||||
@@ -30,7 +30,7 @@ export default (store: Store, logger: Logger) => {
|
||||
server.addListener('error', err => {
|
||||
const payload: string =
|
||||
err.code === 'EADDRINUSE'
|
||||
? "Couldn't start websocket server. Looks like you have multiple copies of Sonar running."
|
||||
? "Couldn't start websocket server. Looks like you have multiple copies of Flipper running."
|
||||
: err.message || 'Unknown error';
|
||||
|
||||
store.dispatch({
|
||||
|
||||
@@ -16,7 +16,7 @@ const plugins = new Map();
|
||||
// $FlowFixMe process.env not defined in electron API spec
|
||||
const remoteEnv = remote.process.env;
|
||||
|
||||
// expose Sonar and exact globally for dynamically loaded plugins
|
||||
// expose Flipper and exact globally for dynamically loaded plugins
|
||||
window.React = React;
|
||||
window.ReactDOM = ReactDOM;
|
||||
window.Flipper = Flipper;
|
||||
|
||||
@@ -147,11 +147,11 @@ export default class Server extends EventEmitter {
|
||||
this.emit(
|
||||
'error',
|
||||
new Error(
|
||||
"Sonar doesn't currently support physical iOS devices. You can still use it to view logs, but for now to use the majority of the sonar plugins you'll have to use the Simulator.",
|
||||
"Flipper doesn't currently support physical iOS devices. You can still use it to view logs, but for now to use the majority of the Flipper plugins you'll have to use the Simulator.",
|
||||
),
|
||||
);
|
||||
console.warn(
|
||||
'Physical iOS device detected. This is not currently supported by sonar.',
|
||||
'Physical iOS device detected. This is not currently supported by Flipper.',
|
||||
'server',
|
||||
);
|
||||
}
|
||||
@@ -267,7 +267,7 @@ export default class Server extends EventEmitter {
|
||||
);
|
||||
|
||||
/* If a device gets disconnected without being cleaned up properly,
|
||||
* sonar won't be aware until it attempts to reconnect.
|
||||
* Flipper won't be aware until it attempts to reconnect.
|
||||
* When it does we need to terminate the zombie connection.
|
||||
*/
|
||||
if (this.connections.has(id)) {
|
||||
|
||||
@@ -269,5 +269,5 @@ export const brandColors = {
|
||||
Facebook: '#4267B2',
|
||||
Messenger: '#0088FA',
|
||||
Instagram: '#E61E68',
|
||||
Sonar: '#8155cb',
|
||||
Flipper: '#8155cb',
|
||||
};
|
||||
|
||||
@@ -38,7 +38,7 @@ const TitleRow = styled(FlexRow)({
|
||||
const Icon = styled(FlexBox)({
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
backgroundColor: brandColors.Sonar,
|
||||
backgroundColor: brandColors.Flipper,
|
||||
width: 32,
|
||||
height: 32,
|
||||
flexShrink: 0,
|
||||
@@ -57,7 +57,7 @@ const Button = styled(View)({
|
||||
borderRadius: 6,
|
||||
color: colors.white,
|
||||
border: 'none',
|
||||
background: brandColors.Sonar,
|
||||
background: brandColors.Flipper,
|
||||
padding: '10px 30px',
|
||||
fontWeight: 500,
|
||||
fontSize: '1em',
|
||||
|
||||
@@ -54,14 +54,14 @@ export type SecureServerConfig = {|
|
||||
|
||||
/*
|
||||
* This class is responsible for generating and deploying server and client
|
||||
* certificates to allow for secure communication between sonar and apps.
|
||||
* certificates to allow for secure communication between Flipper and apps.
|
||||
* It takes a Certificate Signing Request which was generated by the app,
|
||||
* using the app's public/private keypair.
|
||||
* With this CSR it uses the sonar CA to sign a client certificate which it
|
||||
* With this CSR it uses the Flipper CA to sign a client certificate which it
|
||||
* deploys securely to the app.
|
||||
* It also deploys the sonar CA cert to the app.
|
||||
* It also deploys the Flipper CA cert to the app.
|
||||
* The app can trust a server if and only if it has a certificate signed by the
|
||||
* sonar CA.
|
||||
* Flipper CA.
|
||||
*/
|
||||
export default class CertificateProvider {
|
||||
logger: LogManager;
|
||||
@@ -310,14 +310,14 @@ export default class CertificateProvider {
|
||||
.then(output => {
|
||||
if (output.match(appNotDebuggableRegex)) {
|
||||
const e = new RecurringError(
|
||||
`Android app ${user} is not debuggable. To use it with sonar, add android:debuggable="true" to the application section of AndroidManifest.xml`,
|
||||
`Android app ${user} is not debuggable. To use it with Flipper, add android:debuggable="true" to the application section of AndroidManifest.xml`,
|
||||
);
|
||||
this.server.emit('error', e);
|
||||
throw e;
|
||||
}
|
||||
if (output.toLowerCase().match(operationNotPermittedRegex)) {
|
||||
const e = new RecurringError(
|
||||
`Your android device (${deviceId}) does not support the adb shell run-as command. We're tracking this at https://github.com/facebook/Sonar/issues/92`,
|
||||
`Your android device (${deviceId}) does not support the adb shell run-as command. We're tracking this at https://github.com/facebook/flipper/issues/92`,
|
||||
);
|
||||
this.server.emit('error', e);
|
||||
throw e;
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<link rel="stylesheet" href="style.css">
|
||||
<link rel="stylesheet" href="graphiql/graphiql.css">
|
||||
<link rel="stylesheet" href="vis/vis.min.css">
|
||||
<title>Sonar</title>
|
||||
<title>Flipper</title>
|
||||
|
||||
<style>
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<link rel="stylesheet" href="style.css">
|
||||
<link rel="stylesheet" href="graphiql/graphiql.css">
|
||||
<link rel="stylesheet" href="vis/vis.min.css">
|
||||
<title>Sonar</title>
|
||||
<title>Flipper</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
|
||||
Reference in New Issue
Block a user