In my app - i'd like to rename my app for separate variations.
For Android, can I rename the app_name resource at
.\platforms\android\src\main\res\values\strings.xml
Is that the right place?
Ideally I would like the apk file to be the same - but I can rename that later.
Do you have the folder App_Resources under folder App? If so, change the app name at .\app\App_Resources\Android\values\strings.xml. The one that you change in .\platform will get override by this one every time you build the app
to me it's that file :
.\app\App_Resources\Android\src\main\res\values\strings.xml
but then you'll have to quit all processes after uninstalling the app from emulator/device...
So the next time you execute "tns run plateform" it'll rebuild reaching the names set in the strings.
You have control over : Icon name, APP Title name (the action bar title)
Cheers
Related
My old app that name is dd.
Now we rename the app to me and change the icon by updating.
Newest app is built by electron-builder for acrossing the platform.
After upgrading the app can run correctly but the app name not changed on the dock and the Finder Application directory.
The icon changed immediately on Finder Application directory but on the dock must complete quit and restart the icon will be changed.
App name will never change to the new name.
I have try to set resource/xx.lproj/InfoPlist.strings that not working too.
InfoPlist.strings
"CFBundleDisplayName" = "new app name";
"CFBundleName" = "new app name";
Does anyone know what's going on and how to solve this problem?
Sorry for my English
Finally, I found a solution.
First after the app run 3s do below code
execSync('mv /Applications/Old.app /Applications/NewName.app')
Why after running 3s(undetermine, may less or more)? Because I rename immediately the app will crash. If delay some times, It works.
Then I parsed ~/Library/Preferences/com.apple.dock.plist to get the app index by bundle-identifier and file-label and _CFURLString
Then, execute some command line code in child_process
// delete the app on the dock by index
execSync(`plutil -remove persistent-apps.${index} ~/Library/Preferences/com.apple.dock.plist`
execSync(`plutil -insert persistent-apps.${index} -xml "<dict><key>tile-data</key><dict><key>file-data</key><dict><key>_CFURLString</key><string>/Applications/NewAppName.app</string><key>_CFURLStringType</key><integer>0</integer></dict></dict></dict>" ~/Library/Preferences/com.apple.dock.plist & killall Dock`)
Last
spawn('open', ['-n', '-a', '/Applications/NewAppName.app']);
app.quit();
This solution will make flash the screen once for refresh the dock.
I created this Automator app that creates the folders I need to start a new project, but I need to share it with my team, so instead of telling them to open Automator and set the path (doucments/projects/2020/) by themself. I was thinking that maybe they just can paste it in the 2020 folder, run the app and create the project folders in the same folder.
But I don't know how to set a variable with the current path where my Automator App it's saved. Any ideas? Thanks, guys!
My current workflow
To create a new folder in a specific location of the user's home folder, you can use the the special 'location' variables that automator defines. Click the variables tab button in the upper left corner of the automator window to see the full list of available variables...
So, to create a folder hierarchy like the one shown in the link, but at a standardized location in the documents folder, use a flow like the following:
Since Automator doesn't have a specific variable that gives the location of the created workflow app, if you want a path relative to the app's location you'd use a Run AppleScript action and try to path to me command, but every time I've tried it I've received weird errors which make me think that command doesn't work correctly in Automator. I mean, the following ought to produce the correct result, but it consistently errors out:
Maybe you can make it function...
I created a Messages Extension in Xcode 8 using the appropriate template, that seems to be working fine and when I run the extension, it's installed in the Messages app and I can use it without any issues.
My problem is that I wanted to create an actual app to be associated with this extension (so that the user would be able to search the extension through the Messages Store or install the actual app through the App Store). I gave it a matching bundle identifier (my extension is com.XXX.testmessage.MessagesExtension, so for the app I set com.XXX.testmessage), but when I run the app, it doesn't install the extension.
Is it possible to do that? And if so, what am I missing?
In XCode8, open your existing app. Then you need to add a new target to your app (File->New->Target->iOS->Sticker Pack Extension (or an iMessage Extension if you want a custom messages experience)). It will then create a folder visible in Project Navigator. The name of the folder depends on the name you gave to the extension. In that folder you will find a Stickers.xcassets where you can drop your stickers.
This is probably something simple but its driving me crazy...
I was just able to build my first automator workflow, which is quite basic and uses the Subtitles application to download subtitles for movies in a specific folder.
The Actions are:
Get Folder Contents
Filter Finder Items (to only movie files)
Open finder item with the Subtitle app
It works fine when I execute the workflow from within Automator because it has a "Folder Action receives files and folders added to:" clause in the beginning which tells which folder to use.
However, I want to save that as an application so I can schedule that on iCal but, when I save as an app, the clause which tells the folder is no longer available and looks like I need to pass the folder name as a parameter/argument and I have no idea on how to do that.
So, what I need guidance is on how to have the app executed in iCal while telling it which folder to use.
Thanks in advance...
Just add a "run applescript" action above your "Get Folder Contents" action. Make the applescript code look like the following. Make sure to put your folder path between the quotes.
on run {input, parameters}
return "/Users/username/Desktop/"
end run
Note: a quick way to get a path is to run this in Script Editor and use the result.
return POSIX path of (choose folder)
How can I reset a cocoa application in Xcode? When I run my application from Xcode all user default are saved. I would like to reset (delete) my application to create a new one with new settings and run as it would be run first time.
I found one way - I change a name of my app to a different one and it is started as new. But how can I do this with an old name?
You can use the defaults command line tool to remove all the settings, you just need the bundle id of your app (which you can find in your Info.plist file), e.g. if your bundle id is "com.foo.barApp" then you can run this from a terminal shell:
defaults delete com.foo.barApp
Is your app limited to the App Store? If so, I don't think there's a way to delete your entire application, specifically because of the sandbox restrictions. We'd need more information on how you are planning to distribute it to help.
If you just want to delete your app settings, then clear whatever database you store your app data in - [NSUserDefaults +resetStandardUserDefaults], SQLite, App Library directory, whatever. That is dependent on how/where you are storing user data, there's no one size fits all solution.