{"action":"created","issue":{"url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/7077","repository_url":"https://api.github.com/repos/ARMmbed/mbed-os","labels_url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/7077/labels{/name}","comments_url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/7077/comments","events_url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/7077/events","html_url":"https://github.com/ARMmbed/mbed-os/issues/7077","id":328286260,"node_id":"MDU6SXNzdWUzMjgyODYyNjA=","number":7077,"title":"make .mbedignore more like .gitignore","user":{"login":"bmcdonnell-ionx","id":34172339,"node_id":"MDQ6VXNlcjM0MTcyMzM5","avatar_url":"https://avatars2.githubusercontent.com/u/34172339?v=4","gravatar_id":"","url":"https://api.github.com/users/bmcdonnell-ionx","html_url":"https://github.com/bmcdonnell-ionx","followers_url":"https://api.github.com/users/bmcdonnell-ionx/followers","following_url":"https://api.github.com/users/bmcdonnell-ionx/following{/other_user}","gists_url":"https://api.github.com/users/bmcdonnell-ionx/gists{/gist_id}","starred_url":"https://api.github.com/users/bmcdonnell-ionx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bmcdonnell-ionx/subscriptions","organizations_url":"https://api.github.com/users/bmcdonnell-ionx/orgs","repos_url":"https://api.github.com/users/bmcdonnell-ionx/repos","events_url":"https://api.github.com/users/bmcdonnell-ionx/events{/privacy}","received_events_url":"https://api.github.com/users/bmcdonnell-ionx/received_events","type":"User","site_admin":false},"labels":[{"id":515347831,"node_id":"MDU6TGFiZWw1MTUzNDc4MzE=","url":"https://api.github.com/repos/ARMmbed/mbed-os/labels/component:%20tools","name":"component: tools","color":"5319e7","default":false},{"id":427713129,"node_id":"MDU6TGFiZWw0Mjc3MTMxMjk=","url":"https://api.github.com/repos/ARMmbed/mbed-os/labels/mirrored","name":"mirrored","color":"ededed","default":false},{"id":28847981,"node_id":"MDU6TGFiZWwyODg0Nzk4MQ==","url":"https://api.github.com/repos/ARMmbed/mbed-os/labels/type:%20enhancement","name":"type: enhancement","color":"cccccc","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-05-31T20:31:29Z","updated_at":"2018-06-05T15:39:36Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"### Description\r\nChange suggestions to make `.mbedignore` more like `.gitignore`:\r\n1. Make leading slash anchor to the pattern to the current directory. i.e. `/mydir/` matches `./mydir/`, but not `./other/mydir/`; `mydir/` matches either/both.\r\n2. `!` prefix negates a pattern.\r\n\r\n### Issue request type\r\n[ ] Question  \r\n[X] Enhancement  \r\n[ ] Bug  \r\n"},"comment":{"url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/comments/394757716","html_url":"https://github.com/ARMmbed/mbed-os/issues/7077#issuecomment-394757716","issue_url":"https://api.github.com/repos/ARMmbed/mbed-os/issues/7077","id":394757716,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NDc1NzcxNg==","user":{"login":"RaEyE","id":29312954,"node_id":"MDQ6VXNlcjI5MzEyOTU0","avatar_url":"https://avatars3.githubusercontent.com/u/29312954?v=4","gravatar_id":"","url":"https://api.github.com/users/RaEyE","html_url":"https://github.com/RaEyE","followers_url":"https://api.github.com/users/RaEyE/followers","following_url":"https://api.github.com/users/RaEyE/following{/other_user}","gists_url":"https://api.github.com/users/RaEyE/gists{/gist_id}","starred_url":"https://api.github.com/users/RaEyE/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RaEyE/subscriptions","organizations_url":"https://api.github.com/users/RaEyE/orgs","repos_url":"https://api.github.com/users/RaEyE/repos","events_url":"https://api.github.com/users/RaEyE/events{/privacy}","received_events_url":"https://api.github.com/users/RaEyE/received_events","type":"User","site_admin":false},"created_at":"2018-06-05T15:39:36Z","updated_at":"2018-06-05T15:39:36Z","author_association":"NONE","body":"An example would be this. (Again under the assumption mentioned folderstructure is still in use).\r\n\r\nA `.mbedignore` placed at `projects/project01/submodule/` containing the instruction to ignore all files containing `stm32xx_emac.c` or `stm32xx_emac.c` in their name/path.\r\n\r\nDue to the `.mbedignore` system adding the actual subpath (e.g. `projects/project01/submodule/`) in front of the lines stored in `.mbedignore`, following example results are different to what I'd like them to be. Or at least the resulting effect.\r\n\r\n```\r\n*stm32xx_emac.c\r\n*/stm32xx_emac.c\r\n```\r\n\r\nResult:\r\n```\r\nprojects/project01/submodule/*stm32xx_emac.c\r\nprojects/project01/submodule/*/stm32xx_emac.c\r\n```\r\n\r\nThis leads to the effect, that files from the mbed-os folder containing `stm32xx_emac.c` in their name. are still included after an export.\r\n\r\nWhat I'd like the system to do, actualy is, on recognition of a leading `*` in front of a path, is to NOT add the subpath in front of that line. So, although the `.mbedignore` system is supposed to (my interpretation), only ignore files / folder further down it's own location, I'd like a possibility to globaly ignore files.\r\n\r\nTherefore beeing able to ignore files from a mbed-os folder not beeing part of the actual project-path.\r\n\r\nTo prevent naming issues (although a bit more soffisticated) an ignore like this could be used to specifically ignore files or folders that are somewhere deeper down the path of mbed-os.\r\n\r\n`*/mbed-os/*/stm32xx_emac.c`\r\n\r\n\r\nI hope this TL;dr behemoth of a simple example is somewhat understandable and helps you figuring out supporting the mechanism I'm thinking of."}}
{"actor":{"display_login":"RaEyE"}}